cancel
Showing results for 
Search instead for 
Did you mean: 

Which compiler generates the smallest code size?

sima
Associate II
Posted on March 25, 2009 at 06:40

Which compiler generates the smallest code size?

3 REPLIES 3
sima
Associate II
Posted on May 17, 2011 at 13:07

Which compiler for the STM32 generates the smallest code size?

I'm using Ride7 for the moment.

st3
Associate II
Posted on May 17, 2011 at 13:07

Quote:

I'm using Ride7 for the moment.

RIDE7 uses GCC; no doubt the paid-for compilers would claim to give ''better'' code optimisation.

But the final code size is heavily influenced by the quality of the source code - if you write bloated rubbish, no compiler can make a silk purse out of a sow's ear...

Why don't you download the free evaluation versions, and evaluate how each one performs with your particular code...?

vincentchoplin9
Associate II
Posted on May 17, 2011 at 13:07

Hi,

A few years ago, before we (Raisonance) decided to simply interface GCC in Ride, we made some benchmarking for comparing the ARM compilers.

Here are the results:

http://www.mcu-raisonance.com/arm_benchmark.html

Of course these results are for ARM7, not Cortex which was not available at this time. And they are very obsolete because all these compilers have been improved a lot since then. (and ARM bought Keil so now I guess they both use the same compiler...)

Nevertheless, the document shows you the traps to avoid when doing such benchmarking. (printf...)

If you want to do the same benchmarking on the current versions of the compilers and for Cortex, here are the source files of the tests:

ftp://www.raisonance.com/pub/forum/gcc_bench/ARM-C-benchmark.zip

Please let us know the results. ;)

Best Regards,

Vincent

(Raisonance)

[ This message was edited by: VincentC on 25-03-2009 11:16 ]