Kenwood HP 9000 Personal Computer User Manual


 
288 Chapter 8
Ways to Improve Performance
Profile-Based Optimization
Notice in the example above, that the +pgm option was necessary because
the output file name differs from the instrumented program file name.
NOTE If you are using -r and C++ templates, check "Known Limitations" in the
HP C++ Release Notes for possible limitations.
Restrictions and Limitations of PBO
This section describes restrictions and limitations you should be aware of
when using Profile-Based Optimization.
“Temporary Files”
“Source Code Changes and PBO”
“Profile-Based Optimization (PBO) and High-Level Optimization
(HLO)”
“I-SOM File Restrictions”
PBO calls malloc() during the instrumentation (+I) phase. If you
replace libc malloc(3C) calls with your own version of malloc(), use
the same parameter list (data types, order, number, and meaning of
parameters) as the HP version. (For information on malloc(), see
malloc(3C).)
Temporary Files
The linker does not modify I-SOM files. Rather, it compiles, instruments,
and optimizes the code, placing the resulting temporary object file in a
directory specified by the TMPDIR environment variable. If PBO fails due
to inadequate disk space, try freeing up space on the disk that contains
the $TMPDIR directory. Or, set TMPDIR to a directory on a disk with more
free space.
Source Code Changes and PBO
To avoid the potential problems described below, PBO should only be
used during the final stages of application development and performance
tuning, when source code changes are the least likely to be made.
Whenever possible, an application should be re-profiled after source code
changes have been made.