identification division.
Program-Id. COBOLR. date-compiled. author.
E-JCL Software, Inc. * * This sample COBOL program
contains random COBOL statements and * is intended to demonstrate some of the run-time
profiling * capabilities of CobolPro for z/OS. * environment division. configuration section .
source-computer. test-computer-name *
with debugging mode
. object-computer.
test-computer-name. special-names. data division. working-storage
section. 01 PROG-COBOLS
PIC X(8) VALUE '$$COBOLS'. 01 COUNT-A
PIC S9(9) COMP VALUE 3. 01 COUNT-B
PIC S9(9) COMP VALUE 2. 01 COUNT-C
PIC S9(9) COMP VALUE 1. 01 COUNT-D
PIC S9(9) COMP VALUE 0. 01 COUNT-E
PIC S9(9) COMP VALUE 0. * 01 DATE-X
PIC X(8). * procedure division.
* Display 'Executing $$COBOLR *****************'
* Accept DATE-X FROM DATE YYYYMMDD.
* If COUNT-B > COUNT-A next sentence
else continue
end-if. * If COUNT-B
> COUNT-C next sentence else continue end-if. *
If COUNT-C > COUNT-B next sentence else continue end-if. *
Perform 439 times COMPUTE COUNT-A = COUNT-A
+ 2 MOVE COUNT-B TO COUNT-C
MOVE COUNT-A TO COUNT-D ADD 17 TO COUNT-E
DIVIDE COUNT-D BY 7 GIVING COUNT-E SUBTRACT 9 FROM COUNT-C End-Perform *
IF COUNT-A NOT = 0 CALL PROG-COBOLS END-CALL END-IF. * IF COUNT-E > 10000
CALL 'isplink' END-CALL END-IF.
* Perform 517 times
COMPUTE COUNT-B = COUNT-B + 3 ADD
1 TO COUNT-C End-Perform
* If COUNT-C = 10 OR 20 OR 30 OR 400 OR 500
ADD 41 TO COUNT-B End-If
* Perform 088 times
COMPUTE COUNT-C = COUNT-C + 4 End-Perform
* goback
.
|