pTAL Reference Manual (G06.24+, H06.09+, J06.03+)
NAME input_file;
?SOURCE calcsrc(unblocked_globals) ! Specify implicit block
?SOURCE calcsrc(default) ! Specify named block
3. If you then change any declaration within a data block that has a section name, you must
recompile all source files that include SOURCE directives listing the changed data block.
Compiling With Saved Global Data
NOTE: This topic applies only to the pTAL compiler. If you are using the EpTAL compiler, see
Migrating from TNS/R to TNS/E (page 375).
During program development or maintenance, you often need to change procedural code or data
without changing the global declarations. You can save the global data in a file during a compilation
session and then use the saved global data during a subsequent compilation. You can shorten the
compile time by not compiling global declarations each time. For more information, see Saving
and Using Global Data Declarations (page 372).
Using the Code Profiling Utilities
The Code Profiling Utilities provide these capabilities
• Evaluate the code coverage provided by application test cases. The utilities use information
provided by a specially-instrumented object file to produce a report that indicates which
functions and blocks were executed, and how many times each was executed.
• Optimize an application through a process called profile-guided optimization. In profile-guided
optimization, a specially-instrumented object file is executed to produce a data file containing
code profiling information. That data file, along with the original source code, is input to the
compiler to generate more efficient object code.
Using the Code Profiling Utilities requires a special compilation to produce an object file containing
the required instrumentation. To create such an object file, specify the CODECOV or PROFGEN
option on the compiler command line. Several other compiler options are related to code profiling.
These are the PROFDIR, PROFUSE, and BASENAME options.
NOTE: The Code Profiling Utilities are intended for data generation and collection in a test
environment only. The use of instrumented object code is not recommended for production
environments. Applications compiled with code profiling instrumentation will experience greatly
reduced performance.
For details on using the Code Profiling Utilities, see the Code Profiling Utilities Manual.
366 Compiling and Linking pTAL Programs