z/OS MVS Programming: Extended Addressability Guide
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF


PC routine that receives control in primary mode

z/OS MVS Programming: Extended Addressability Guide
SA23-1394-00

After receiving control, the PC routine must establish a general register as a base register. The PC routine must also initialize general register 13:
  • If the PC routine calls other routines, the PC routine must initialize general register 13 to the address of an 18-word save area that's located on a word boundary in the PC routine's primary address space. The PC routine must initialize the second word of the save area to the value C‘F1SA’. The value C‘F1SA’ indicates that the system saved the user's environment on the linkage stack. IBM® recommends that all PC routines that receive control in primary mode initialize general register 13 in this way.
  • A PC routine that does not call other routines and does not wish to provide an 18-word save area must initialize general register 13 to one of the following values.
    • Zero.
    • The address of a two word save area that's located on a word boundary in the PC routine's primary address space. The PC routine must initialize the second word of the area to the value C‘F1SA’.

    Either value, zero or C‘F1SA’, in general register 13 indicates that the system saved the user's environment on the linkage stack.

Addressability to the latent parameter area is through the primary address space. When the PC routine receives control, general register 4 contains the address of the latent parameter area.

Before returning control to the user, the PC routine must:
  • Free any save area or work area it obtained.
  • If there are parameters to pass, place their address into general register 0 or 1.
  • If there is a return code, place it into general register 15.

To restore the user's environment and to return control, the PC routine must issue the PR instruction.

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014