Creating a new task (ATTACH or ATTACHX macro)

To create a new task, use the ATTACH or ATTACHX macro. Programs running in primary ASC mode or programs running in access register ASC mode can use either ATTACH or ATTACHX. IBM® recommends, however, that programs running in access register ASC mode use ATTACHX. The ATTACH and ATTACHX services for programs that run in problem program state are described in the z/OS MVS Programming: Assembler Services Guide and the z/OS MVS Programming: Assembler Services Reference ABE-HSP.

When you attach a subtask, you have the option of setting its dispatchability. The DISP parameter of the ATTACH and ATTACHX macros enables you to set the attached subtask to be dispatchable (DISP=YES) or non-dispatchable (DISP=NO). You can reset tasks that you attached with the DISP=NO parameter to dispatchable by issuing ATTACH or ATTACHX again with the DISP=RESET parameter.