Hallo
I have been looking into compiler optimazation. My project has a level of 0 - No optimazation As I can read from the help file, default is level 2. Using level 2 will decrease the size but also remove the possiblity to debug. Thats ok for released version of the software.
But are there any benefits, other then smaller code size, using compiler optimazation? I mean, is there any performance gain ? Better interrupt respons etc? I don't have any problem fitting un-optimized code into the flash.
But if using optimazation makes it hard to debug, then its difficult to "debug" any problems caused by the optimazation? Is there any gurantie, that if the code work with no optimazation, then its behaves the same with optimazations on??
/Thomas
The optimization will not just change the code size, but also the execution speed.
So, there can be no warranty at all that a program that works without optimization will also work with optimization enabled - or the reverse.
Because of this, you must perform all testing using the same compiler settings that you will use when releasing your applciation for production.