13.1 Register Variables

Register variables use one or more working registers, as shown in the following table.

Table 13-1. Register Conventions
VariableArchitectureRegister (Note 1)
char, signed char, unsigned charAllW0-W14
short, signed short, unsigned shortAllW0-W14
int, signed int, unsigned intAllW0-W14
void * (or any pointer)AllW0-W14
long, signed long, unsigned longdsPIC33C/E/F and dsPIC30FAn even pair of contiguous W registers such as W1:W0
dsPIC33AW0-W14
long long, signed long long, unsigned long longdsPIC33C/E/F and dsPIC30FA quadruplet of contiguous W registers such as W3:W2:W1:W0
dsPIC33AAn even pair of contiguous W registers such as W1:W0
floatdsPIC33C/E/F and dsPIC30FAn even pair of contiguous W registers such as W1:W0
dsPIC33AAny register from F0-F31
double(Note 2)dsPIC33C/E/F and dsPIC30FAn even pair of contiguous W registers such as W1:W0
dsPIC33AAny register from F0-F31
long doubledsPIC33C/E/F and dsPIC30FA quadruplet of contiguous W registers such as W3:W2:W1:W0
dsPIC33AAn even pair of registers F registers such as F1:F0
structdsPIC33C/E/F and dsPIC30F1 contiguous register per 2 bytes in the structure
dsPIC33A1 contiguous register per 4 bytes in the structure
_Fract

_Sat _Fract

dsPIC33C/E/F and dsPIC30FW0-W14
long _Fract

_Sat long _Fract

dsPIC33C/E/F and dsPIC30FA pair of contiguous registers, the first of which is a register from the set {W0, W2, W4, W6, W8, W10, W12}
_Accum

_Sat _Accum

dsPIC33C/E/F and dsPIC30FThree contiguous registers where the first register starts in the set {W0, W4, W8, W12}; W12 is included only if W14 is not used as a frame pointer.
Note:
  1. W14 is not available for selection if it is being used as a Frame Pointer.
  2. double is equivalent to long double if -fno-short-double is used.