Using the EXTRACT macro to find the UCB address

This procedure can only be used by application programs that are the only task running in an address space, for either non-concatenated DD statements or data sets that reside on a single volume. This procedure works only for allocations that did not use the XTIOT or UCB nocapture options of dynamic allocation.

Use the EXTRACT macro to obtain information from the task control block (TCB). The address of the TIOT can be obtained from the TCB in response to an EXTRACT macro. Before issuing an EXTRACT macro, set up an answer area to receive the requested information. One fullword is required for each item to be provided by the control program. If you want to obtain the TIOT address, you must specify FIELDS=TIOT in the EXTRACT macro.

The control program returns the address of the TIOT, right adjusted, in the fullword answer area.