Kang Tin LAI schrieb:
Hi,

My old code (a bootloader) compiled with 4.0.3 + avr-libc 1.4.4 the code size is 1068 bytes, but same code compiled with 4.3.3 + avr-libc 1.6.6 the code size is 1332 bytes!

Optimization option is -Os, boot_page_xxx and boot_rww_xxx library functions are called only.

Have a look at the asm code that avr-gcc generates together with -fverbose-asm. To get the asm code specify -save-temps.

The .s will list the -f switches enabled by -Os. Look out for switches that changed from 4.0.3 to 4.3.3. Observe their effect on the generated asm by diff'ing avr-gcc's output.

Maybe some of
-fno-inline-small-function
-fno-split-wide-types
-fno-move-loop-invariants

or setting inline limits will bring some improvement.

Georg-Johann


_______________________________________________
AVR-GCC-list mailing list
AVR-GCC-list@nongnu.org
http://lists.nongnu.org/mailman/listinfo/avr-gcc-list

Reply via email to