|
|||||||||||
|
Technical Support On-Line Manuals Linker User Guide |
Linker User GuideUsing __attribute__((section("name"))) to place code and data
You can place code and data by separating them into their
own objects without having to use toolchain-specific pragmas or
attributes. However, you can also use To use
The following example shows the memory map for the
...
Load Region FLASH (Base: 0x24000000, Size: 0x00000004, Max: 0x04000000, ABSOLUTE)
Execution Region ADDER (Base: 0x08000000, Size: 0x00000004, Max: 0xffffffff, ABSOLUTE)
Base Addr Size Type Attr Idx E Section Name Object
0x08000000 0x00000004 Data RW 16 foo file.o
...
Be aware of the following:
You can also place a function at a specific address using
int sqr(int n1) __attribute__((section(".ARM.__at_0x20000")));
int sqr(int n1)
{
return n1*n1;
}
| ||||||||||
|
|||||||||||