[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [avr-gcc-list] How to set section order
From: |
David Bourgeois |
Subject: |
Re: [avr-gcc-list] How to set section order |
Date: |
Thu, 19 Jan 2006 00:11:40 +0100 |
User-agent: |
Opera M2/8.51 (Win32, build 7712) |
In the source code, the smaller function comes after but is located before
in the .lss file.
With optimization -O0, it's correctly located after.
I attached the source code and the makefile (generated by avrstudio) I use
if it can be of any help.
Thanks
On Wed, 18 Jan 2006 23:22:52 +0100, Eric Weddington
<address@hidden> wrote:
David Bourgeois wrote:
Yes. I noticed that without optimization, the linker keep the order
the functions appear in the code but if I turn on optimization (-Os)
then the smaller function comes first.
Hmm. That seems contradictory to me, so I must not be understanding you
correctly.
Yes, the smaller function comes first in your *source code*? Or, no, it
comes after the bootloader.
In my experience, the compiler keeps the order, no matter what the
optimization. But this could be something new.
--
David Bourgeois
C2ME - Centre de Conception en Microtechnologies Européen sa
Parc Initialis - Rue René Descartes, 2 - 7000 Mons (Belgium)
Phone : +32 65 37 42 25 - Fax +32 65 37 42 36
bootloader.c
Description: Binary data
Makefile
Description: Binary data