TAL Programmer's Guide

TAL and C Guidelines
Mixed-Language Programming
17–34 096254 Tandem Computers Incorporated
6. You must keep track of addresses stored in extended pointers. When storing
addresses into subsequent pointers, you must allow space for preceding data
items. (See “Managing Data Allocation in Extended Segments” in Appendix B.)
7. To refer to data in the current segment, call READX or WRITEX .
8. To move data between extended segments, call MOVEX.
9. To manage large blocks of memory, call DEFINEPOOL, GETPOOL, and
PUTPOOL.
10. To determine the size of a segment, call SEGMENT_GETINFO_.
11. To access data in the automatic extended segment, call SEGMENT_USE_ and
restore the segment number that you saved at step 4.
12. To delete an explicit segment that you no longer need, call
SEGMENT_DEALLOCATE_.
For information on using these system procedures, see the Guardian Programmer's
Guide and the Guardian Procedure Calls Reference Manual.
If you do not restore the automatic extended data segment before you manipulate data
in it, any of the following actions can result:
An assignment statement is beyond the segment's memory limit and causes a trap.
All assignments within range occur in the hardware base and limit registers of the
automatic extended segment. Data in the currently active extended segment is
overwritten. The error is undetected until you discover the discrepancy at a later
time.
The C code runs until it accesses an invalid address or accesses an inaccessible
library routine.
You get the wrong data from valid addresses in the explicit extended data
segment.