5.15.2.2 Data Memory Classes
The following linker classes defined by the compiler represent data space memory. Not all classes will be present for each device.
RAM
- Consists of ranges that cover all the general purpose RAM memory of the target device, but excluding any common (unbanked) memory. Thus, it is useful for psects that must be placed within any general-purpose RAM bank.
BIGRAM
- Consists of a single memory range that is designed to cover the linear data memory of Enhanced Mid-range devices, or the entire available memory space of PIC18 devices. It is suitable for any psect whose contents are accessed using linear addressing or which does not need to be contained in a single data bank.
ABS1
- Consists of ranges that cover all the general purpose RAM memory of the target device, including any common (unbanked) memory. Thus, it is useful for psects that must be placed in general purpose RAM, but can be placed in any bank or the common memory,
BANKx
- (where
x
is a bank number) — each consist of a single range that covers the general purpose RAM in that bank, but excluding any common (unbanked) memory. COMMON
- Consists of a single memory range that covers the common (unbanked) RAM, if present, for all Mid-range devices.
COMRAM
- Consists of a single memory range that covers the common (unbanked) RAM, if present, for all PIC18 devices.
SFRx
- (where
x
is a number) — each consists of a single range that covers the SFR memory in bank x. These classes would not typically be used by programmers as they do not represent general purpose RAM. STACK
- Consists of a single memory range in which the software (data) stack (represented by
the
stack
psect) can be placed. The compiled stack does not use this class. The address range of this class is based on information relating to the stack sizes present in the-mstack
option, or default size values where these are omitted or specified asauto
. If you require more memory for the software stack, use the-mstack
option to do this. If you need to relocate the software stack to a specific area of memory, then you can override the definition for this class.