TAL Programmer's Guide
Addressing Modes
Introducing the Environment
096254 Tandem Computers Incorporated 4–5
System Code Space The current system code space available to your process contains one segment of
system code.
System Library Space The current system library space contains up to 31 segments of system library code,
available to your process one at a time.
Registers Table 4-1 lists the registers that describe your process in the current process
environment:
Table 4-1. Registers in Current Process Environment
Register Content
Program (P) register Contains the address of the next instruction to execute in the current
code segment
Instruction (I) register Contains the instruction currently executing in the current code segment
Local (L) register Contains the address of the beginning of the local data area for the
current procedure
Stack (S) register Contains the address of the last allocated word in the data stack for the
current procedure or subprocedure
Register stack Contains registers (R0 through R7) that the compiler uses for arithmetic
and other operations. The compiler also uses R5, R6, and R7 as index
registers.
Environment (E) register Contains information about the current process, such as the current RP
value and whether traps are enabled
Register pointer (RP) A field of the environment register that points to the current top of the
register stack
Addressing Modes When you declare a variable, you specify its addressing mode and an identifier and a
data type. You can specify these addressing modes:
Direct addressing
Standard indirect addressing
Extended indirect addressing
The addressing mode and scope of a variable determines:
The storage area in which the compiler allocates space for the variable
The kind of instructions the compiler generates to access the variable
The data type of a variable determines the byte or word addressing mode of the
variable. Figure 4-3 shows byte and word addresses in the user data segment.
(Extended segments are always byte addressed.)