Preparing Enterprise COBOL for z/OS Version 4 programs

Perform the following steps for compiling your Enterprise COBOL for z/OS Version 4 programs using the compiler options suggested in Table 1:
  1. Create libraries (PDSE is suggested unless PDS is required in your organization) for SYSDEBUG files. Create one or more SYSDEBUG libraries for each environment, such as test, production, and so on.
  2. Create a corresponding SYSDEBUG library for each load library. Specify LRECL=(80 to 1024),RECFM=FB,BLKSIZE=(multiple of lrecl < 32K).
  3. For all programs in both test and production environments, specify the following compiler options: TEST(NOHOOK,SEPARATE,EJPD),LIST,MAP,SOURCE,NONUMBER,XREF(SHORT).

    The TEST compiler option is required if you plan to use Debug Tool for z/OS to debug a program. The TEST option is optional if you plan to use Fault Analyzer for z/OS or Application Performance Analyzer for z/OS.

    The SEPARATE sub-option produces a SYSDEBUG file.

    NOHOOK and SEPARATE produce a production-ready module that can still be debugged.

    If the OPT option is also used, EJPD might reduce optimization but enables the debugger’s JUMPTO and GOTO commands. These commands are disabled when OPT and NOEJPD are both used.

  4. When the TEST option is not used, save the compiler listing in a file, or use the xxxLANGX utility program to create a LANGX file. Equivalent xxxLANGX utilities are available in Debug Tool for z/OS as EQALANGX, in Fault Analyzer for z/OS as IDILANGX and in Application Performance Analyzer for z/OS as CAZLANGX. Fault Analyzer for z/OS and Application Performance Analyzer for z/OS can use compiler listings and LANGX files to provide source-level support.
  5. The LIST, MAP, SOURCE, and XREF options are needed only if a compiler listing or a LANGX file will be used to provide source information to Fault Analyzer for z/OS or Application Performance Analyzer for z/OS. If a SYSDEBUG file will be used with these products or if you will not be using Fault Analyzer for z/OS or Application Performance Analyzer for z/OS, the LIST, MAP, SOURCE, and XREF options are optional.
  6. The NONUMBER compiler option is needed only if a compiler listing file will be used to provide source information to Application Performance Analyzer for z/OS. If a SYSDEBUG file will be used with Application Performance Analyzer for z/OS, or if you will not be using Application Performance Analyzer for z/OS, the NONUMBER option is optional.
  7. Code a SYSDEBUG DD in the JCL of the compiler step:
     //SYSDEBUG DD DSN= SYSDEBUG.pds(pgmname),DISP=SHR
    Save the SYSDEBUG file produced by the compiler in the SYSDEBUG library and specify a member name that is equal to the program name of your application program. This is the source information file for Debug Tool for z/OS, Fault Analyzer for z/OS and Application Performance Analyzer for z/OS.
  8. Modify the promotion process to promote SYSDEBUG files. When a load module is promoted, for example from test to production, promote the corresponding SYSDEBUG file or files. A promotion can be a recompile, copy, or move. Perform the same steps with the SYSDEBUG file that you perform with the module during promotion.
  9. Optionally, include a Debug Tool Language Environment (LE) exit module into the load module during the linkage editor step. This is one way to enable Debug Tool’s panel 6 in ISPF, a simple panel-driven method to start the debugger automatically when a program runs, without JCL changes, based on the program name and user ID. Use module EQADBCXT for batch programs (including IMS batch), EQADICXT for IMS/TM programs and EQADDCXT for DB2 stored procedures. Do not include the exit module for CICS programs.