[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[avr-gcc-list] Code optimistaion in AVR Tiny13
From: |
Robert von Knobloch |
Subject: |
[avr-gcc-list] Code optimistaion in AVR Tiny13 |
Date: |
Mon, 16 Feb 2009 15:11:34 +0100 |
User-agent: |
Thunderbird 1.5.0.14 (X11/20060911) |
Hello,
I write code for Tiny13 embedded applications using 'C' to improve
maintainability. Due to some small issues I decided to update my entire
toolchain to the latest (greatest?) versions. Upon going back to some
old projects I notice that re-compiling makes the code grow quite
horribly. In one case the 'main' function has increased from it's
original 0x10c Bytes to 0x15c Bytes (ca. 30%). This was especially
apparent because the code would no longer fit in the target device (1024
Bytes).
On inspection I find that the compiler has 'in-lined' at least 3
function calls that I had written as a function to achieve compactness.
Is there any way I can stop this, or is this a bug?
I am using:
avr-gcc compiled from gcc-core-4.3.2
binutils-2.19
avr-libc-1.6.4
My Makefile:
PRG = ES04
OBJ = $(PRG).o
MCU_TARGET = attiny13
OPTIMIZE = -Os
DEFS =
LIBS =
CC = avr-gcc
override CFLAGS = -g -Wall -Wno-main $(OPTIMIZE)
-mmcu=$(MCU_TARGET) $(DEFS)
override LDFLAGS = -Wl,-Map,$(PRG).map
-Wl,--section-start=.testparms=0x880
<snip>
I would appreciate any thoughts before I think about returning to the
old compiler (whose version I have, of course, forgotten). I imagine
there will be quite a few people interested in small devices who also
will get bitten here.
Regards,
Robert von Knobloch.
- [avr-gcc-list] Code optimistaion in AVR Tiny13,
Robert von Knobloch <=
- Re: [avr-gcc-list] Code optimistaion in AVR Tiny13, Ruud Vlaming, 2009/02/16
- Re: [avr-gcc-list] Code optimistaion in AVR Tiny13, Anatoly Sokolov, 2009/02/16
- [avr-gcc-list] RE: inline control, larry barello, 2009/02/16
- [avr-gcc-list] Re: inline control, David Brown, 2009/02/16
- RE: [avr-gcc-list] Re: inline control, Weddington, Eric, 2009/02/16
- [avr-gcc-list] Re: inline control, David Brown, 2009/02/16
- RE: [avr-gcc-list] Re: inline control, Weddington, Eric, 2009/02/16
[avr-gcc-list] Re: Code optimistaion in AVR Tiny13, David Brown, 2009/02/16