Linker Script - Placing a section at the end of a memory region

前端 未结 5 1515
后悔当初
后悔当初 2020-12-24 09:15

I have searched far and wide for how to do this and have failed to come up with an answer.

My memory layout is as follows:

Fake Address | Section
            


        
5条回答
  •  温柔的废话
    2020-12-24 10:02

    what I want to do is place a single section, let's call it .persist, into my ram memory. I want it to reside at the very end of RAM and I want to program this into my linker script.

    Linker script has special variable called Location Counter which allows to modify the current address, and as such the size or address of a section or symbol, by creating gaps or holes in the address space.

提交回复
热议问题