Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » C / C++ IDE (CDT) » How to tell Eclipse+GNU tools to skip unused memory in one section and do not download?
How to tell Eclipse+GNU tools to skip unused memory in one section and do not download? [message #1786729] Thu, 10 May 2018 03:57
Wilson Wang is currently offline Wilson WangFriend
Messages: 4
Registered: April 2018
Junior Member
I am using:
Eclipse IDE for C/C++ Developers Oxygen Release (4.7.0)
GNU Tools ARM Embedded(arm-none-eabi version of GNU tools)
GDB SEGGER J-Link Debugging plugin

In my linker script, I have a memory segment(.myvars) which contains two discontinuous sections(.loadtable and .rawdata)

sections.ld:
.myvars :
{
    __myvars_start__ = ABSOLUTE(.);
    __loadtable_start__ = 0x60002000;
    . = __loadtable_start__ - __myvars_start__;
    *(.loadtable)
    __rawdata_start__ = 0x60039000;
    . = __rawdata_start__ - __myvars_start__;
    *(.rawdata)
} > MYVARS

Illustration:
.myvars 0x60000000
          |
          |        (unused memory)
          |
          |        .loadtable 0x60002000
          |                     |
          |                     |
          |                     |
          |                   0x60002000 + sizeof(.loadtable)
          |
          |        (unused memory)
          |
          |        .rawdata   0x60039000
          |                     |
          |                     |
          |                     |
          |                   0x60039000 + sizeof(.rawdata)
          |
          |        (unused memory)
          |
        0x60800000

Using sections.ld, Eclipse download 0x60000000 ~ (0x60039000 + sizeof(.rawdata)) to my device. But I hope I can just download .loadtable and .rawdata.

I know I can achieve by using this linker script(place section in two separate memory segment):
.myvars1 :
{
    *(.loadtable)
} > MYVARS1

.myvars2 :
{
    *(.rawdata)
} > MYVARS2


Is it possible to skip unused memory in one memory segment when downloading?
Any advice on this issue? I would be grateful for any suggestions.

[Updated on: Thu, 10 May 2018 04:05]

Report message to a moderator

Previous Topic:Eclipse builds with different sizes
Next Topic:Unable to toggle breakpoint
Goto Forum:
  


Current Time: Tue Apr 16 04:36:04 GMT 2024

Powered by FUDForum. Page generated in 0.06508 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top