This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Arm compiler 6 - How to get linker section info? Execution base address and size

Hi,

I'm using compiler version 6 and building M55 image for FVP SSE-300-MPS3.

I would like to get section actual size using the are arm linker auto generated variables and use it in c code.

Image$$section_name$$Length;
Image$$section_name$$Base;
image$$section_name$$Limit; 

I'm using ARM scatter file below but can't get the correct info.

here is sample scatter file with 3 regions.

c main code part.


The map file out put indicates the following:

Execution Region ARM_LIB_STACK (Exec base: 0x20060000, Load base: 0x00003b98, Size: 0x00008000, Max: 0x00008000, ABSOLUTE)

Execution Region dtcm (Exec base: 0x20000000, Load base: 0x00003b80, Size: 0x00000014, Max: 0xffffffff, ABSOLUTE)

Execution Region dtcm_ZI (Exec base: 0x20000014, Load base: 0x00003b94, Size: 0x00008b10, Max: 0xffffffff, ABSOLUTE)

The output of the my code is as follw:

The ARM_LIB_STACK section Length  0x20068000 Base 0x20060000  Limit 0xdfdfdfcf
The dtcm section                      Length  0x1ddd         Base 0x20000000  Limit 0x0
The dtcm_ZI section                 Length 0x20068000  Base 0x20000014  Limit 0x0

Any idea how can I get the actual size of the regions? e.g. for dtcm_ZI size 

0