[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: [avr-gcc-list] code size: .text vs .data
From: |
Dave Hylands |
Subject: |
RE: [avr-gcc-list] code size: .text vs .data |
Date: |
Fri, 11 Jun 2004 10:32:27 -0700 |
You need to modify your linker script. This is what defines how much
space goes where.
What's the exact command that you used to link your program?
--
Dave Hylands
Vancouver, BC, Canada
http://www.DaveHylands.com/
> -----Original Message-----
> From: address@hidden
> [mailto:address@hidden On Behalf Of Pat Deegan
> Sent: Friday, June 11, 2004 10:10 AM
> To: address@hidden
> Subject: [avr-gcc-list] code size: .text vs .data
>
>
> Greetings,
>
> I am currently creating my first AVR program that goes beyond
> the classic uC "hello world" program (flashing LEDs).
>
> I am hitting an unexpected barrier in terms of executable
> size. I'm compiling for the ATmega32 and the program size is now
>
> $ avr-size a.out
> text data bss dec hex filename
> 7654 512 162 8328 2088 a.out
>
> Adding any more functionality causes the linker to barf out an
> ld: region text is full (a.out section .text)
> error.
>
> I'd expected the 32k flash of this chip to give me plenty of
> room but it looks like I'm hitting an 8k limit for code size,
> while the data segment is sitting there, empty.
>
> My questions are:
>
> - Is there a way to increase the .text space?
>
> - Failing that, is there a way to executing OPs loaded in registers?
> Basically storing assembly in the .data segment and
> "interpreting" it from there.
>
> - Can you give me any hints on minimizing use of .text/moving
> stuff into .data?
>
>
> TIA
>
> Regards,
> --
> Pat Deegan
> http://www.psychogenic.com/
> PGP Key: http://www.keyserver.net 0x03F86A50
>
>
> _______________________________________________
> avr-gcc-list mailing list
> address@hidden
> http://www.avr1.org/mailman/listinfo/avr-gcc-list
>
>