Preparing Enterprise PL/I Version 3.5 and Version 3.6 programs

Perform the following steps for compiling your Enterprise PL/I Version 3.5 and Version 3.6 programs:

  1. Create a library (PDSE is suggested unless PDS is required for your organization) for SYSDEBUG files. This library is only needed in test environments where debugging is performed using LRECL=(80 to 1024),RECFM=FB,BLKSIZE=(multiple of lrecl < 32K).
  2. Allocate one or more LANGX libraries for each environment, such as test and production.
  3. Create a corresponding LANGX library for each load library. Specify LRECL=1562 or greater,RECFM=VB,BLKSIZE= lrecl+4 to 32k.
  4. Run a two-stage compile. The first stage preprocesses the program, so the IBM® Application Delivery Foundation for z Systems family of products have access to fully expanded source code with INCLUDEs and macros. The second stage compiles the program. For all programs, such as batch, CICS®, and IMS:
    • In the first compile stage, in both test and production environments, specify compiler options MACRO,MDECK,NOCOMPILE,NOSYNTAX,INSOURCE to expand INCLUDEs and macros. The output SYSPUNCH DD is the input SYSIN DD to the second compile stage.
    • In the second compile stage, in test environments,
      • When using the Enterprise PL/I Version 3.5 compiler:

        For all programs, specify the following compiler options: TEST(ALL,SYM,NOHOOK,SEPARATE), NOPT, AGGREGATE, ATTRIBUTES(FULL), NOBLKOFF, LIST, MAP, NEST, NONUMBER, OFFSET, OPTIONS, SOURCE, STMT, XREF(FULL).

      • When using the Enterprise PL/I Version 3.6 compiler:

        For all programs, specify the following compiler options: TEST(ALL,SYM,NOHOOK,SEPARATE,SEPNAME), NOPT, AGGREGATE, ATTRIBUTES(FULL), NOBLKOFF, LIST, MAP, NEST, NONUMBER, OFFSET, OPTIONS, SOURCE, STMT, XREF(FULL).

      TEST(…) and NOPT are required by z/OS® Debugger.

      The SEPARATE suboption produces a SYSDEBUG file. Save the SYSDEBUG file that is created by the compiler for z/OS® Debugger (and optionally, Fault Analyzer).

      The other options format the compiler listing as required for the IPVLANGX utility.

      Consider using TEST(ALL,SYM,NOHOOK,SEPARATE) for best performance and to produce a module that can be debugged. Depending on the policies in your organization, the module can be considered for production.

    • In the second compile stage, in production environments, specify compiler options NOTEST, AGGREGATE, ATTRIBUTES(FULL), NOBLKOFF, LIST, MAP, NEST, NONUMBER, OFFSET, OPTIONS, SOURCE, STMT, XREF(FULL).
      Note: The above options can be used with both the Enterprise PL/I Version 3.5 and Version 3.6 compilers.

    NOTEST disables z/OS® Debugger, but produces a smaller load module.

    The other options format the compiler listing as required for the IPVLANGX utility to produce a production-ready module that can be used with Fault Analyzer for z/OS® and Application Performance Analyzer for z/OS® (but not z/OS® Debugger).

  5. When a TEST(…SEPARATE) parm is used, code a SYSDEBUG DD in the second compiler step as follows:
    //SYSDEBUG DD DSN= sysdebug.pds(pgmname),DISP=SHR
    This is the source information file for z/OS® Debugger, IBM® Application Performance Analyzer for z/OS® and optionally, IBM® Fault Analyzer for z/OS®. Save it in the SYSDEBUG library, and specify a member name that is equal to the primary entry point name or CSECT name of your application program.
  6. Modify the SYSPRINT DD in the second compiler stage. This file is the compiler listing. Write the listing to either a permanent or temporary file. This file is the input to the IPVLANGX utility.
    Note: This compiler typically renames CSECTs according to an internal compiler algorithm. Therefore, it is not recommended to store PL/I compiler listings or side files using CSECT names as they might not be found by IBM® Application Performance Analyzer for z/OS® or IBM® Fault Analyzer for z/OS®. Instead, use the primary entry point name.
  7. Add a step after the compile step to run the IPVLANGX utility. This utility reads the compiler listing and generates a LANGX file. This file is the source information file for IBM® Fault Analyzer for z/OS® and IBM® Application Performance Analyzer for z/OS®. Save the LANGX file in the LANGX file library, and specify a member name that is equal to the primary entry point name of your application program.
  8. Modify the promotion process to promote LANGX files. When a load module is promoted, for example, from test to production, promote the corresponding LANGX file or files. A promotion can be a recompile, copy, or move. Perform the same steps with the LANGX file that you perform with the module during promotion.
  9. If you compile with the TEST option and promote these modules into production, promote the SYSDEBUG file for your production environment.
  10. Optionally, include a z/OS® Debugger Language Environment® exit module into the load module during the linkage editor step. This approach is one way to enable z/OS® Debugger 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.

    You can also use module EQAD3CXT for batch programs, IMS/TM, IMS BTS programs, and DB2® type MAIN stored procedures