Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.

Application Profiling 346 + All of the Itanium and Itanium2 PMU counters can be used to track down particular events in an application. + HTML output capability to easily view and traverse output results. + Can attach and detach dynamically from a running process. + PMU measurements can be restricted to particular parts of the application via code modifica- tions to the application. + Most of the measurement scripts are lightweight and don't adversely affect the run-time of the application being measured. + Ability to profile multiple processes in a process tree. + Provides global, per-module, per-function, and per-bundle statistics. + Events can be correlated with source code in the application. - It does not currently work with PA-RISC applications. - There is no way to dynamically attach to more than one process at a time. - Some of the configuration scripts may greatly slow down the application. - It is supported only on HP-UX 11i v1.6 and later operating systems. - Knowledge of IPF assembly language and the IPF architecture may be needed to fully under- stand the profiled data. CXperf CXperf is an interactive run-time performance analyzer for programs written in HP Fortran 77, For- tran 90, ANSI C, ANSI C++, and Assembler. CXperf also profiles multi-process (threaded) applica- tions, message passing parallel programming models (including the Message Passing Interface, an API from HP), object files and archive libraries, and shared memory applications, including those that employ pthreads and user-specified parallel directives. CXperf can only be used on D-, K-, N- and V-Series HP 9000 systems because it requires special hardware instrumentation that is avail- able only on these models. Additionally, CXperf runs only on HP-UX 11.0 (9806) or later. As of early 2003, CXperf has been discontinued and replaced with Caliper . CXperf provides a powerful tool for application optimization by giving measurements of the following metrics on a procedure basis: · · · · · · · Procedure execution count CPU time Wallclock time Instruction counts Instruction and data TLB misses Instruction and data cache hits and misses Context switches · Thread CPU switches CXperf also provides a complete call graph that shows the parent/child relationships of each of the procedures. The main CXperf executable is cxperf, which has the following syntax: cxperf [ executable ] [ pdf-filename ] [-options...] where executable is the program to profile (the default is a.out ) and pdf-filename is a performance data file (PDF) created by CXperf for analysis. The default is <executable-program-name>.pdf .