MPLAB C Compiler for PIC24 MCUs and dsPIC DSCs ... - Microchip
MPLAB C Compiler for PIC24 MCUs and dsPIC DSCs ... - Microchip
MPLAB C Compiler for PIC24 MCUs and dsPIC DSCs ... - Microchip
You also want an ePaper? Increase the reach of your titles
YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.
__builtin_subab<br />
Built-in Functions<br />
Description: Subtracts acumulators A <strong>and</strong> B with the result written back to the<br />
specified accumulator. For example:<br />
register int result asm("A");<br />
result = __builtin_subab();<br />
will generate:<br />
sub A<br />
Prototype: int __builtin_subab(void);<br />
Argument: None<br />
Return Value: Returns the subtraction result to an accumulator.<br />
Assembler Opera- subad<br />
tor / Machine<br />
Instruction:<br />
Error Messages An error message will be displayed if the result is not an accumulator<br />
register.<br />
__builtin_tblpage<br />
Description: Returns the table page number of the object whose address is given as<br />
a parameter. The argument p must be the address of an object in an<br />
EE data, PSV or executable memory space; otherwise an error message<br />
is produced <strong>and</strong> the compilation fails. See the space attribute in<br />
Section 2.3.1 “Specifying Attributes of Variables”.<br />
Prototype: unsigned int __builtin_tblpage(const void *p);<br />
Argument: p object address<br />
Return Value: Returns the table page number of the object whose address is given as<br />
a parameter.<br />
Assembler Operator<br />
/ Machine<br />
Instruction:<br />
tblpage<br />
Error Messages The following error message is produced when this function is used<br />
incorrectly:<br />
“Argument to __builtin_tblpage() is not the address of an object<br />
in code, psv, or eedata section”.<br />
The argument must be an explicit object address.<br />
For example, if obj is object in an executable or read-only section, the<br />
following syntax is valid:<br />
unsigned page = __builtin_tblpage(&obj);<br />
__builtin_tbloffset<br />
Description: Returns the table page offset of the object whose address is given as a<br />
parameter. The argument p must be the address of an object in an EE<br />
data, PSV or executable memory space; otherwise an error message is<br />
produced <strong>and</strong> the compilation fails. See the space attribute in<br />
Section 2.3.1 “Specifying Attributes of Variables”.<br />
Prototype: unsigned int __builtin_tbloffset(const void *p);<br />
Argument: p object address<br />
Return Value: Returns the table page number offset of the object whose address is<br />
given as a parameter.<br />
© 2008 <strong>Microchip</strong> Technology Inc. DS51284G-page 159