6.1.4 D: Define Class Delta Value
The -Dclass=delta
option defines the delta
value for the address ranges
specified for a class.
The delta
value should be a number. It
represents the number of bytes per addressable unit of objects within the
psects. The default value is 1, which is the correct value for most classes
needed by PIC devices. The delta
value assigned to a class
should match that assigned to the psects that are linked in the class (see
4.9.47.4 Delta Flag).
delta
value associated with any psects linked into
this memory should be set to 2. Such a value means that two bytes of data
are needed to program a single address location in this space. The data
memory on these devices is byte addressable, so a delta
value of 1 is appropriate for classes representing such memory. The assembler automatically specifies the
-D
linker option for any linker classes it defines
and that need a non-unity delta
value. If you define your
own linker classes and those classes will be used to represent program
memory addresses, you will need to use this option with each of those
classes. For example, the following linker options define a program memory
class called MYCODE
and set a delta
value
of 2 for that
class.-AMYCODE=0h-07FFhx4 -DMYCODE=2