EmbDev.net

Forum: ARM programming with GCC/GNU tools defining .bss section in SDRAM


Author: Amit Chatre (aseem)
Posted on:

Rate this post
0 useful
not useful
Hi,

     I'm able to interface SDRAM with lpc2478.But now my .bss section is
too large to fit in SRAM, & trying to locate entire .bss section in
SDRAM.
     Is it right to use SDRAM for storing variables in SDRAM? Will it
affects my code.

Thanks.

Author: Martin Thomas (mthomas) (Moderator)
Posted on:

Rate this post
0 useful
not useful
Amit Chatre wrote:
>      I'm able to interface SDRAM with lpc2478.But now my .bss section is
> too large to fit in SRAM, & trying to locate entire .bss section in
> SDRAM.
Create an additional memory area in the linker-script and assign the
.bss (.bss.*) C-sections to this area. Take the given
section-definitions as templates. Make sure to enable/setup the
memory-interface before writing zeros to bss during startup.

>      Is it right to use SDRAM for storing variables in SDRAM? Will it
> affects my code.
I do not fully understand you question. Maybe the access to the external
SDRAM will be slower than internal SRAM. Check the datasheet and the
RAM-interface setup (wait-states, bus-width etc.).
For performace reasons it might be better keep the "standard" bss in
internal SRAM end use the extra sections for huge arrays in external RAM
(see gcc-manual variable attribute section).

Reply

Entering an e-mail address is optional. If you want to receive reply notifications by e-mail, please log in.

Rules — please read before posting

  • Post long source code as attachment, not in the text
  • Posting advertisements is forbidden.

Formatting options

  • [c]C code[/c]
  • [avrasm]AVR assembler code[/avrasm]
  • [code]code in other languages, ASCII drawings[/code]
  • [math]formula (LaTeX syntax)[/math]




Bild automatisch verkleinern, falls nötig
Note: the original post is older than 6 months. Please don't ask any new questions in this thread, but start a new one.