section placement file preprocessor
In the section placement file, we have lines such as:
<MemorySegment name="$(RAM_NAME:RAM);SRAM">
I assume the "$(RAM_NAME:RAM);SRAM" part gets replaced with the real name of a section defined in the memory map file.
How can I determine the real section name?
I found this page:
From which:
"When a section placement file is used for linking it is preprocessed using the (as yet undocumented) CrossWorks XML preprocessor."
Thanks
-
$(RAM_NAME:RAM) expands to RAM if the macro RAM_NAME has not been defined in the Linker > Section Placement Macros project property. If it has been defined, it will expand the RAM_NAME macro. The conditional macro syntax is described here.
The linker script generator searches through the ';' separated list of memory sections described in the section placement file until it finds a memory segment in the memory map file with a matching name. When it finds a match it places all the sections in that memory segment.
You can find out where a section has been placed in memory using the memory usage window, the symbols browser or by looking at the generated linker script.
Please sign in to leave a comment.
Comments
2 comments