z/OS TSO/E REXX Reference
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF


Format of the environment block (ENVBLOCK)

z/OS TSO/E REXX Reference
SA32-0972-00

Table 1 shows the format of the environment block. TSO/E provides a mapping macro, IRXENVB, for the environment block. The mapping macro is in SYS1.MACLIB.

When IRXINIT initializes a new language processor environment, IRXINIT returns the address of the new environment block in register 0 and in parameter 6 in the parameter list. You can use the environment block to locate information about a specific environment. For example, the environment block points to the REXX vector of external entry points that contains the addresses of routines that perform system services, such as I/O, data stack, and exec load. Using the control blocks lets you easily call one of the routines.

Table 1. Format of the environment block
Offset (decimal) Number of bytes Field name Description
0 8 ID An eight-character field that identifies the environment block. The field contains the characters ‘ENVBLOCK’.
8 4 VERSION A 4-byte field that contains the character representation of the version number of the environment block. The version number is 0100.
12 4 LENGTH The length of the environment block. The number is 320, in decimal.
16 4 PARMBLOCK The address of the parameter block (PARMBLOCK). See Format of the parameter block (PARMBLOCK) for more information.
20 4 USERFIELD The address of the user field that is passed to IRXINIT if you explicitly called IRXINIT. You pass the user field in parameter 4 (see Initialization routine - IRXINIT for information about the parameters). You can use this field for your own processing. The TSO/E REXX services do not use this field.
24 4 WORKBLOK_EXT The address of the current work block extension. If an exec is not currently running in the environment, the address is 0. See Format of the work block extension for details about the work block extension.
28 4 IRXEXTE The address of the REXX vector of external entry points. See Format of the REXX vector of external entry points for details about the vector.
32 4 ERROR_CALL@ The address of the TSO/E REXX routine that encountered the first error in the language processor environment and that issued the first error message. The error could have occurred while an exec was running or when a particular service was requested in the environment.
36 4 Reserved.
40 8 ERROR_MSGID An eight-character field that contains the message ID of the first error message the system issued in the language processor environment. The message relates to the error encountered by the routine that is pointed to at offset +32.
48 80 PRIMARY_ERROR_MESSAGE An 80-character field that contains the primary error message (the message text) for the message ID at offset +40.
128 160 ALTERNATE_ERROR_MESSAGE A 160-character field that contains the alternate error message (the message text) for the message ID at offset +40.
288 4 COMPGMTB The address of the compiler programming table for the language processor environment. The table identifies a compiler runtime processor and corresponding compiler interface routines. If a compiler programming table is not available to the language processor environment, this field is 0. For information about the compiler programming table, see z/OS TSO/E Customization.
292 4 ATTNROUT_PARMPTR The address of an attention handling routine control block. The attention handling exit can optionally use this control block to communicate with REXX attention processing. For more information about the control block, see z/OS TSO/E Customization.
296 4 ECTPTR The address of the ECT under which this environment is anchored. This field is only used for environments which are integrated into TSO/E. Otherwise, it is zero.
300 4 INFO_FLAGS A fullword of bits that gives status of this environment block. Bit 0 is the only bit that is used. Bits 1 through 31 are reserved.
  • Bit 0 (TERMA_CLEANUP). This bit is on if the environment is undergoing abnormal termination. (See IRXTERMA routine for information about abnormal termination.

The following topics describe the format of the parameter block (PARMBLOCK), the work block extension, and the vector of external entry points.

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014