The XPLINK stack

Stack storage is automatically created by Language Environment and is used for routine linkage and automatic storage. This topic describes the way the XPLINK stack differs from the standard Language Environment stack, which is described in detail in Stack storage overview.

The prolog of a function usually allocates space (referred to as a "frame", "Stack Frame", or "DSA" - dynamic storage area) in the Language Environment-provided stack segment for its own purposes and to support calls to other routines.

Figure 1 shows the structure of the standard Language Environment stack. Note that the DSAs in the standard (upward-growing) Language Environment stack are allocated from lower to higher addresses. Figure 2 shows how the XPLINK (downward-growing) stack is different, specifically that the DSAs are allocated from higher to lower addresses, with the presence of the guard page to mark the bottom of the stack.

Figure 1. Standard stack storage model
In this depiction of the structure of the stack, the DSAs are allocated from lower to higher addresses.
Figure 2. XPLINK stack storage model
In this downward-growing stack, the DSAs are allocated from the higher to lower addresses. The guard page marks the bottom of the stack.