|
|||||||||||
Technical Support Support Resources
Product Information |
C51: RET_XSTK DirectiveInformation in this article applies to:
QUESTIONWhat does the RET_XSTK directive do? ANSWERThe RET_XSTK directive causes the xdata reentrant stack to be used for return address. Normally, return addresses are stored on the 8051's hardware stack. This directive instructs the compiler to generate code that pops the return address from the hardware stack and stores it on the xdata reentrant stack. You may use the RET_XSTK directive to unload return addresses from the on-chip (hardware) stack. This directive may be selectively used on the modules that contain the deepest stack nesting. If you use this directive, you must initialize the ?C_XBP reentrant stack pointer defined in the startup code. The following example demonstrates the code generated to push and pop the return address on the pdata stack.
SEE ALSO
Last Reviewed: Thursday, February 25, 2021 | ||||||||||
|
Arm’s Privacy Policy has been updated. By continuing to use our site, you consent to Arm’s Privacy Policy. Please review our Privacy Policy to learn more about our collection, use and transfers
of your data.