|ARM Technical Support Knowledge Articles|
Applies to: LX51 Linker/Locator
Information in this article applies to:
We are using Linker Code Banking and the linker generates segments with the name ?L?COMxxxx. However, we need to locate these segments to a specific address region. Since these segments always belong to the memory class CODE it seems to be impossible to locate them.
I have even tried to use a wildcard in the SEGMENTS directive (for example ?L?COM*(C:0x2000)) but this does not work either.
Is there any way to locate these segments in specific address ranges?
The linker generated segments with the name ?L?COMxxxx are generated very late during the optimization process. The only way to locate them is to use the memory class CODE. When you need to locate your application code to a specific memory region, you may use the USERCLASS directive.
The required steps for the setup in µVision are explained below:
HDATA (X:0x0-X:0xFFFF), ECODE (C:0x0-C:0xFFFF), HCONST (C:0x0-C:0xFFFF), CODE (C:0-C:0x1FFF), CODE_APP (C:0x2000-C:0xFFFF)
This locates the common code sequences to C:0 - C:0x1FFF and the application code to C:0x2000 - C:0xFFFF.
Note: The linker generates the common code sequences very late and therefore the size is not known when the application code segments are located. You may need to adjust the address ranges for the different memory classes when you are getting *** ERROR L107: ADDRESS SPACE OVERFLOW linker errors.
Article last edited on: 2006-08-17 19:58:42
Did you find this article helpful? Yes No
How can we improve this article?