Mainframe
Documentation

Version Latest

Control flow, data elements and data flow

IDz's Program Control Flow, Perform Hierarchy and Data Element views for COBOL with copybooks expanded, and the data flow of a data item across MOVE, arithmetic, CALL USING, Db2 and CICS.

Verification state: these are the module's own analyses of the source, verified on Linux on the payroll project and all 44 AWS CardDemo programs: no undefined targets, unreachable paragraphs, called programs and a 300-byte record's offsets checked against the source; data flow traced for all 397 level-01 items of 31 programs. Offsets are not compared with an Enterprise COBOL listing (MAP). Windows and macOS are not verified.

Program control flow

Show Program Control Flow opens an editor for the program with:

  • nodes for the entry, sections, paragraphs, called programs and ending statements;
  • edges for PERFORM, PERFORM THRU, GO TO (with DEPENDING ON and CICS HANDLE labels), fall-through, CALL, CICS LINK and XCTL, and GOBACK, STOP RUN, EXIT PROGRAM and CICS RETURN.

Unreachable paragraphs, found by PERFORM-range reachability, are dashed and labelled; Go to Next Unreachable Paragraph moves between them. A click or Enter opens the paragraph in the source.

ALTER and dynamic CALL targets are not followed for reachability. Measured: a program with 105 nodes and 1,453 data items in 69 ms; a 5,000-paragraph program opens in about 580 ms.

Perform hierarchy

Show Perform Hierarchy (Shift+Alt+H) is the call hierarchy for COBOL, from the PROCEDURE DIVISION entry, incoming and outgoing, each item saying how it is reached.

Data elements

The Data Elements view in the panel lists every data item of the program with:

  • level, PICTURE and USAGE;
  • offset and length by Enterprise COBOL's rules (the Record Viewer's layout engine);
  • OCCURS and REDEFINES, and the copybook it comes from;
  • the statements that set it and that read it.

A filter narrows the list. Show in Data Element View in the editor selects the item under the cursor. Records the layout engine rejects (a REDEFINES larger than its object below level 01, OCCURS with REDEFINES, USAGE POINTER) show no offsets and say why.

Data flow of a data item

Show Data Flow on a data item follows where its value comes from and where it goes:

  • MOVE (and CORRESPONDING), arithmetic, INITIALIZE, SET, ACCEPT;
  • READ and RETURN INTO, WRITE, REWRITE and RELEASE FROM;
  • STRING, UNSTRING, INSPECT, JSON and XML statements;
  • CALL USING into a called program of the workspace (BY REFERENCE both ways);
  • Db2 INTO and host variables; CICS INTO, FROM and COMMAREA, into the DFHCOMMAREA of programs reached by LINK and XCTL.

Group moves reach their subordinates byte for byte, and REDEFINES are followed. The result shows as a graph in the control flow editor's style, or as a Comes From and Goes To tree.

It is a static reading: every statement is taken to run. Callers are not traced from a LINKAGE item. Measured: each traced item under a second.

Last reviewed 18 October 2026View as Markdown

Control flow, data elements and data flow · Docs · Neural Inverse