GNU ARM “Debugger Optimizations” for PSoC | Cypress Semiconductor
GNU ARM “Debugger Optimizations” for PSoC
About a week ago I wrote about how we try to respond to user feedback at Cypress. As a result of one such interaction we discovered that, with debugging enabled, the v4.8 GNU ARM compiler optimizes for code space far more efficiently than the prior versions. We ll be updating the compiler in our next release.
Another thing that came out of our tests was that there is a new command-line flag, -Og . This flag turns on debugger-friendly optimizations so that the code size can be compressed even closer to the fully-optimized value, while still allowing the use of the debugger (debugging fully optimized code is worse than listening to Coldplay believe me, it's really painful!). Re-running last week s tests, I found that the new option brought the code size down from 36710 to just 23798 bytes, which is pretty close to the best case (all optimization enabled) of 21534! The work being done on Launchpad for this compiler toolchain is really yielding good results right now!
We ll be starting an early access program for PSoC Creator 3.1 in a few days. You will be able to get a sneak peak at the new software a couple of months before it goes on general release. The main change is actually support for new PSoC devices (I ll post more on those soon) but the new GNU ARM compiler is included and we d love to hear from you about that.
The default GNU compiler remains v4.7 but you can choose the new one from the Build Settings (shown) and re-build to see the code size savings (note that this improvement is in the DEBUG mode, with most optimizations disabled). If you like the results you can also add the Og flag and get even better code compression. And you will still be able to debug!
Please give this a try and let us know how you get on. I watch for comments here and you can email us directly on firstname.lastname@example.org. Let us know what you think good or bad it all helps to make our software better.
[re-posted from ARM Connected Community]