Optimizing the debugging of large applications
z/OS® Debugger is
designed to implicitly load the debug data for any compile units compiled with the
TEST
or DEBUG
compiler option. However, some very large
applications can contain a large number of load modules or compile units that you do not need to
debug. In some cases, the creation and manipulation of debug data for these load modules or
compile units can consume a significant amount of memory, CPU time, and other resources.
You can handle this situation in one of the following ways:
- Change the default behavior so that z/OS Debugger loads debug data only for modules that you indicate that you want to debug.
- Indicate to z/OS Debugger that you do not want to debug certain modules.
In some instances, even when the
OPT
compile option is not used, the
compiler can optimize the code:- By collapsing several statements into one single statement.
- By not creating the object code for a specific statement and instead using a
NOOP
instruction. - By removing the duplicate code.
OPT
compile option, the debugger is not aware of such optimization and does not take any measures. To
make the behavior more predicable when you debug such applications, use any of the following approaches:- Compile with
TEST(EJPD)
to reduce optimization. - Compile with a combination of
OPT(x)
andTEST(EJPD/NOEJPD)
to make the debugger be aware of the optimization and control the optimization performed by the compiler.