Yes, I agree that a STATIC call has less overhead to be loaded and even invoked.
However, that does not explain why the TIMEUSED macro returns wrong Values. Basically: CALL WS-CPUTIME USING WS-START-VALUE might give a value of 1000 microseconds. <-- Dynamic COBOL Call Do some CPU intensive work. also COBOL CALL WS-CPUTIME USING WS-END-VALUE might give a value of 15000 microseconds. The code can then report that the work used 14,000 micoseconds of CPU. The static version gives: CALL 'CPUTIME' USING WS_VALUE gets a value of Zero. <-- Static COBOL CALL. Do some CPU intensive work CALL 'CPUTIME' USING WS-END-VALUE might give a crazy high of value of 005323254020.214122 (seconds.micoseconds) The only change made in the COBOL code is: --: CALL WS-CPUTIME vs: CALL 'CPUTIME' and the routine gets crazy different results. ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to [email protected] with the message: INFO IBM-MAIN
