Listing options decide how much paper—or how many spool lines—your compile step produces. Easytrieve separates listing control into PARM-level switches on the first source line and mid-source LIST statements that toggle printing as the compiler walks your program. A thousand-line payroll program with fifty FILE copybooks can generate a listing larger than the source itself when LIST ON MACROS and full DEBUG maps are active. Production compile procs shrink that volume with LIST OFF, LIST NOMACROS, and NOPARM while development keeps verbose output for new hires learning offset arithmetic from DMAP. Options Table defaults from Configuration Manager establish site baselines—LISTPRM for parameter summary, global DMAP/XREF defaults—overridden per program when PARM says otherwise. This tutorial covers PARM LIST FILE and LIST PARM, LIST ON/OFF and MACROS/NOMACROS, NEWPAGE and SKIP formatting, PUSH/POP stacking, compile summary contents, JCL DD routing, storage of listings for audit, and pairing listing options with debugging options without redundant output.
On PARM, LIST accepts FILE, NOFILE, PARM, and NOPARM combinations documented in Language Reference. LIST FILE enables file statistics sections at activity boundaries—record counts, organization hints useful when validating FILE definitions against JCL. LIST PARM prints compile summary showing parameters in effect—critical when comparing dev and prod compile outcomes. NOPARM suppresses that summary when archives need only source and diagnostics.
| Option | Effect |
|---|---|
| LIST FILE | Include file statistics in listing |
| LIST NOFILE | Omit file statistics section |
| LIST PARM | Print compile summary and active parameters |
| LIST NOPARM | Suppress compile summary parameter block |
After PARM, LIST ON prints all subsequent source statements in the listing until LIST OFF. Default at program start is LIST ON MACROS per Controlling Compilation documentation. LIST OFF after FILE definitions is a common pattern: keep Library layout visible once, hide repetitive JOB and REPORT logic from listing bulk. LIST ON before a complex PROC restores visibility for the section under maintenance.
12345678910111213141516PARM DEBUG(DMAP XREF) LIST FILE FILE PAYMAST FB(150 1500) EMP-NO 1 6 N GROSS 94 5 P 2 LIST OFF REPORT PAY-RPT TITLE 01 'PAYROLL' SYSDATE ... LIST ON COMPLEX-PROC. PROC * detailed logic under review END-PROC
Macros expand before compile logic sees final source. LIST MACROS prints expanded statements— essential when %INCLUDE or cataloged macros generate DEFINE blocks you did not type manually. LIST NOMACROS omits expansion detail, shrinking listing size for stable macro libraries. Macro debugging page pairs with NOMACROS-off compiles until substitution errors resolved.
NEWPAGE starts a fresh listing page—use before large REPORT section for readability. SKIP n inserts blank lines. PUSH saves current LIST and MACROS settings; change temporarily with LIST OFF NOMACROS; POP restores prior settings without remembering original combination. Nested PUSH/POP stacks like conditional compilation discipline—document depth in team standards.
When LIST PARM active, summary aggregates error and warning counts, compiler options, macro libraries searched, generated code size estimates, and execution options embedded at compile. Before promoting load module, diff summary against golden baseline proc—unexpected DEBUG flag is release defect smoking gun.
Configuration Manager LISTPRM option mirrors PARM LIST PARM at site level. Compiler Options DMAP, XREF, PMAP defaults interact with listing volume—listing options page focuses on LIST family; see debugging and cross-reference pages for DEBUG-specific sections.
| Profile | Typical settings | Goal |
|---|---|---|
| Developer debug | LIST ON MACROS, LIST FILE PARM, full DEBUG maps | Maximum visibility |
| Maintenance fix | LIST ON near changed PROC, DMAP on PARM | Targeted section focus |
| Production compile | LIST OFF NOMACROS, NOPARM, minimal DEBUG | Small listing, fast compile |
| Support case | Per article 55089—MACROS on, LIST FILE | Upload complete listing to Broadcom |
Listing options tell the printer how much of your homework to photocopy. LIST ON copies every line; LIST OFF skips lines until you turn copying back on. MACROS means also photocopy the hidden template pages that expanded into real lines. PARM at the top can ask for an extra cover sheet summarizing which copying rules you picked.
1. LIST OFF in source:
2. PARM LIST PARM controls:
3. LIST MACROS versus LIST NOMACROS:
4. PUSH and POP listing statements:
5. LIST FILE on PARM: