z390 Portable Mainframe Assembler and Emulator

ZPAR - z390 and zcobol
Program Analysis Reports

zcobol Portable Mainframe COBOL Compiler
Welcome to z390 and zcobol Program Analysis Reports documentation website.  The ZPAR utilities and reports documented here are all written in structured macro assembler and are included with the installation of z390 portable mainframe assembler starting with PTF v1.5.00e.  The utility ZPARGEN supports batch assembly or compile of all the source programs in a directory with a single command.  For example, all the z390 demo programs in the demo directory can be assembled with the single command: 

       zpar\ZPARGEN    ASM        demo\*.MLC

All the zcobol demo programs in the demo directory zcobol\demo can be compiled with the single command:

     zpar\ZPARGEN     ZC390C   zcobol\demo\*.CBL

The report generator ZPARERR can be used to summarize all the ERR files generated by the z390 assembler

in a directory showing the total number of occurrences of any error messages and the total number of ERR files found.  For example following the above batch assembly of demo programs, the following command will generate report summarizing any errors found:

     zpar\ZPARERR     demo\*.ERR

The report generator ZPARTRS (TRace Source) can be used to obtain an execution trace showing the assembler source statement for each instruction executed along with the PSW address, condition code, module name, and relative offset within the module of the source line.  For example the following command will generate execution source trace report for the demo program demo\DEMO.MLC:

asmlg                     demo\DEMO trace           (assemble, link, and execute with trace)  
zpar\ZPARTRS     demo\DEMO                     (read trace TRE, LST, and PRN files for source trace)

See examples of COBOL, Assembler, and EXEC CICS source execution traces

The utility FIXCRLF simple copies all the specified ASCII source files adding ASCII CR/LF at the end of each line.  This has been used with files created with just LF at the end of each line as some editors and programs require both CR and LF. 

Any and all comments, suggestions, requests, and volunteer contributors are welcome.  Join the z390 email group and post to the group or email me directly.

Don Higgins
President, Automated Software Tools Corporation



ZPARGEN can be used to assemble or compile all the programs in a directory.  It can also be used to execute any specified batch command for selected files in a directory.  The command syntax is as follows:

   zpar\ZPARGEN  command dir\file.type

             command - is any batch command such as ASM or ZC390C

             dir\file.type - is a directory and file selection specification such as demo\*.mlc or

A temporary file named zpar\TEMPGEN.DIR is generated containing directory records for selected files.  A temporary file named zpar\TEMPGEN.BAT is generated containing calls to the specified command for each selected file.  Then TEMPGEN.BAT is called to execute the commands.


ZPARERR - Error Summary Report

ZPARERR can be used to summarize all the errors generated in z390 ERR files in a directory.  The command syntax is as follows:

       zpar\ZPARERR dir\file

       dir\file - is a directory and file selection specification such as demo\* or zcobol\demo\*

A temporary file zpar\ZPARERR.DAT is generated with all the selected ERR file records.  A temporary report file zpar\ZPARERR.RPT is generated with the following summary of the ERR records:

1.  Current date and time of report and file selection specified
2.  Date and time stamps from beginning and end of selected ERR records
3.  Total ERR records read and total summary keys stored
4.  Group 1 - total step START and END records found with count of each different return code
5.  Group 2 - total occurrences for each missing macro or copybook
6.  Group 3 - total errors for each file with 1 or more errors
7.  Group 4 - total occurrences for each error message type
8.  Group 5 - total occurrences for each MNOTE message
9.  Group 6 - total occurrences of any other ERR file messages including blank lines


ZPARMLC - Frequency Distribution of MLC Operation Codes

This command reads one or more MLC or BAL type source files and generates report with frequency distribution of the operation codes found.  First the counts and opcodes are listed in descending order by frequency and then alphabetically by operation code.  See zcobol NIST test program generated opcodes for examples.

ZPARSUM1 - Error Summary Report with START/STOP by 2 char program prefix

Same summary of ERR file statistics as ZPARERR with addition of breaking down program START and STOP statistics by 2 character program name prefix.  The command syntax is as follows:

zpar\ZPARSUM1 dir\file


ZPARSUM2 - Summary report of program translation, assembly, and execution by 2 character prefix

This command executes ZPARSUM1 and then ZPARSUM2 to produce summary report by 2 character prefix showing the number of programs translated, assembled, and executed with return code 0 or >0.  For example see the NIST COBOL 1985 test results.  The command syntax for this command is as follows:

zpar\ZPARSUM2 dir\file


FIXCRLF - Fix carriage return and line feed

FIXCRLF can be used to insert carriage return character (X'0D' at end of each ASCII line preceding line feed character (X'0A').  This is required by some older ASCII editors and other text processing programs.  The command syntax is as follows:

   zpar\FIXCRLF dir\file.type newtype

      dir\file.type - is a directory and file selection specification such as mydir\*.*

      newtype - new file type to be assigned to each new output file mydir\*.newtype


IBM, CICS, HLASM, MVS, OS/390, VSAM, z9, z10, and z/OS
 are registered trademarks  of International Business Machines Corporation

This page last updated Wednesday May 23, 2012.   Webmaster
Copyright 2011 Automated Software Tools Corporation