 | LARM User's Guide Discontinued |  |
|
|
| CLASSES Linker Directive| Abbreviation | CL | | Arguments | CLASSES (class (range〚, ...〛) 〚, ...〛) | | Default | None. | | µVision | Options — LA Locate — User Classes. | | Description | The CLASSES directive allows you to specify an address range (range) for a class (classname). This directive is used to define the memory layout of your application program or target hardware. The LA Linker uses the following default class settings if no explicit class ranges are specified: | Class | Address Range |
|---|
| CODE | 0x00000000-0xFFFFFFFF | | CONST | 0x00000000-0xFFFFFFFF | | DATA | 0x00000000-0xFFFFFFFF | | ERAM | 0x00000000-0xFFFFFFFF |
Note - The address ranges used are listed in the linker MAP file in the Memory Classes section. You should check this section of the MAP file to verify that the linker assumptions about the memory in your hardware matches your physical system.
Specifying the memory range for a class... The CLASSES directive is typically specified as follows to define an address range for a memory class:
CLASSES (class (range〚, ...〛) 〚, ...〛)
Where | class | is the name of the class. | | range | is the address range to assign to the class. All segments within a class are located and must fit within this range. |
Note - You may specify multiple ranges for a memory class.
| | See Also | SEGMENTS | | Example | The following example defines the memory classes for an ARM device:
LA MYFILE.OBJ &
CLASSES (CODE (0 - 0x7FFFF), CONST (0x1000-0x7FFFF),
DATA (0x40000000-0x40003FFF, 0x80000000,0x801FFFFF))
The following example defines a user-defined memory class XDATA_FLASH:
LA MYFILE.OBJ &
CLASSES (CODE_FLASH (0x80000-0x8FFFF))
|
|
|