TAL Programmer's Guide
Accessing the Upper 32K-Word Area
Managing Addressing
096254 Tandem Computers Incorporated B–3
You can use the $XADR standard function to convert the 16-bit address contained in a
standard simple pointer to a 32-bit address with which to initialize an extended simple
pointer:
INT .std_ptr := %100000; !Declare INT standard simple
! pointer
INT .EXT ext_ptr := $XADR(std_ptr);
!Declare extended simple pointer
! initialize it with 32-bit
! address returned by $XADR for
! INT item pointed to by STD_PTR
Assigning Addresses to Simple Pointers
Once you have declared a pointer, you can use assignment statements to assign an
address to the pointer.
You can assign to a standard simple pointer the first standard word address in the
upper 32K-word area of the current user data segment:
INT .std_ptr; !Declare standard simple pointer
@std_ptr := %100000; !Assign first word address
! in upper 32K-word area
You can assign to an extended simple pointer the first extended byte address in the
upper 32K-word area of the current user data segment:
INT .EXT top_ptr; !Declare extended simple pointer
@top_ptr := %200000D; !Assign first byte address
! in upper 32K-word area
You can use the $XADR standard function to return the extended address of an INT
item to which a standard simple pointer points and then assign the 32-bit address to
an extended simple pointer:
INT .EXT ext_ptr; !Declare extended simple pointer
INT .std_ptr := %100000; !Declare INT standard simple
! pointer
@ext_ptr := $XADR(std_ptr);!Assign 32-bit address of
! INT item returned by $XADR