Of course, as we all know <G>, IBM has dropped support for the VS COBOL II
compiler YEARS ago. Therefore, let me provide some information from the
CURRENT "IBM Enterprise COBOL" performance tuning paper:
"Performance considerations using DYNAM with CALL literal (measuring CALL
overhead only):
On the average, for a CALL intensive application, the overhead associated
with the CALL using
DYNAM ranged from 16% slower to 100% slower than NODYNAM.
Note: This test measured only the overhead of the CALL (i.e., the subprogram
did only a GOBACK);
thus, a full application that does more work in the subprograms is not
degraded as much."
but also
"Using CALLs
When using CALLs, be sure to consider using nested programs when possible.
The performance of a CALL to a nested program is faster than an external
static CALL; external dynamic calls are the slowest. CALL identifier is
slower than dynamic CALL literal. Additionally, you should consider space
management tuning (mentioned earlier in this paper) for all CALL intensive
applications.
With static CALLs, all programs are link-edited together, and hence, are
always in storage, even if you do not call them. However, there is only one
copy of the bootstrapping library routines link-edited with the application.
With dynamic CALLs, each subprogram is link-edited separately from the
others. They are brought into storage only if they are needed. However, each
subprogram has its own copy of the bootstrapping library routines
link-edited with it, bringing multiple copies of these routines in storage
as the application is executing.
Performance considerations for using CALLs (measuring CALL overhead only):
CALL to nested programs was 50% to 60% faster than static CALL.
Static CALL literal was 45% to 55% faster than dynamic CALL literal.
Static CALL literal was 60% to 65% faster than dynamic CALL identifier.
Dynamic CALL literal was 15% to 25% faster than dynamic CALL identifier.
Note: These tests measured only the overhead of the CALL (i.e., the
subprogram did only a GOBACK); thus, a full application that does more work
in the subprograms may have different results."
***
Note: NONE of this deals with the "ease" or "difficulty" in maintenance (and
re-testing). It should also be noted that STATIC calls require link-editing
in object code. Therefore, there is LIMITED advantages of static calls
(rather than dynamic calls) over NESTED programs and/or COPY procedures -
when it comes to maintenance issues.
***
For the full Performance Paper, see:
http://www.ibm.com/support/docview.wss?rs=203&q=7001475&uid=swg27001475
--
Bill Klein
wmklein <at> ix.netcom.com
Post by henry weesieWe are using CobolII in a idms mainframe.
I'm told that using copy-members should generate less cpu than using
subprograms and therefore the use of copy-members should be preferred
above the use of subprograms.
So far my employer uses copy statements to copy source into each
program. However they are open for other structures like using
call-statements.
I expect more advantages of using calls instead of copy's in respect
of maintenance. No compile of all programs using copy when source in
the object is changed, no separate declarations en subroutines when
using calls.
But much more expensive CPU?
I'd like to have a strong case in trying to set up some form of object
oriented programming in Cobol II.
What are your experiences in the use of calls versus copy's?