avr-libc-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [avr-libc-dev] noinitdata section ?


From: Theodore A. Roth
Subject: Re: [avr-libc-dev] noinitdata section ?
Date: Fri, 30 Aug 2002 09:22:55 -0700 (PDT)

On Fri, 30 Aug 2002, Joerg Wunsch wrote:

:) As Theodore A. Roth wrote:
:)
:) > Is it possible to tell the linker where to put the .noinit section
:) > (i.e. at an address in a device that is memory mapped into the
:) > external sram space)?
:)
:) avr-gcc ... -Wl,--section-start=.noinit=0x802000 ...
:)
:) The only crock is that the 0x800000 offset used for normal .data
:) variables needs to be added manually.  (The linker complains about
:) your .noinit getting outside of the data region otherwise.)

Good timing, I was just about to commit the dox for sections. Will add
this first since it fills a little gap. ;-)

That offset is needed because of the Harvard nature of this beast. Just to
be clear (so I can write it up in the docs), you are saying that if you
want your .noinit to live at address 0x2000 in sram, you have to manually
add 0x800000 to the addr you give as the start of the section. Otherwise,
the linker thinks you are tried to put the .noinit section into the .text
section instead of .data/.bss.  Right?

Ted Roth





reply via email to

[Prev in Thread] Current Thread [Next in Thread]