Sv Pablo Sv Pablo Source view Pablo GUI
Sv. Pablo
Sv. Pablo • Source view Pablo • GUI for instrumenting source code and viewing runtime performance data • Joint work at Univ. of Illinois and Rice Univ. • HPF programs automatically instrumented by PGI HPF compiler • C programs interactively instrumented using GUI • Fortran 77/90 parser developed at JPL
Sv. Pablo Project • Set of application source files • One or more performance contexts • Performance context includes – instrumentation specification - source code points where performance measurements are to be inserted – set of performance data files in SDDF, generated when instrumented code is run • Source files and parser options are shared among all contexts.
Sv. Pablo Main Window
Project Menu
Project Menu Selections • • • New Project Open Project Edit Project Select Project Base Directory Load Color Configuration Exit Sv. Pablo
Sv. Pablo on-line help
New Project dialog box
Edit Project dialog box
Instrumentation of HPF Programs • Given appropriate flags, the PGI HPF compiler automatically inserts calls to Sv. Pablo instrumentation library routines at the beginning and end of every procedure and for each executable line. • After compiling and linking with the Sv. Pablo HPF trace library, the user runs the instrumented executable which generates per-process trace files. • User runs HPFCombine to merge per-process trace files into a single performance file SDDF format.
Overview of HPF Instrumentation
Compiling and Linking Compile with pghpf flag -Mprof=lines to active calls to the Sv. Pablo HPF trace library: % pghpf -c -Mprof=lines part 1. F % pghpf -c -Mprof=lines part 2. F Link with flag -Mprof=lines to activate calls to both the. Sv. Pablo HPF trace library and the PGI profiler library. Link with flag -Mprof=stats to activate only calls to the Sv. Pablo HPF trace library: % pghpf -Mprof=stats part 1. o part 2. o /usr/local/Sv. Pablo/lib/pghpf 2 SDDF. o
Procedure Metrics • • • Count Exclusive Duration Inclusive Duration Send Msg Duration Receive Msg Duration
Line Metrics • • • Count Duration Exclusive Duration Message Send Count Message Send Size Message Receive Duration Message Receive Count Message Receive Size
Performance Statistics • Performance file contains the following statistics for the procedure and line performance metrics: – mean – standard deviation – minimum value – process corresponding to minimum value – maximum value – process corresponding to maximum value
Performance view of HPF program
Performance statistics for subroutine relax
Instrumentation of C Programs • Use GUI to instrument selected constructs in C source files • Compile instrumented source files and link with Sv. Pablo C Trace Library • Run instrumented executable • Combine per-process trace files using CCombine
Overview of C Instrumentation
C Instrumentation GUI
Multiple instrumentable constructs in source line
Instrument options for routine main
Files Created By Saving Instrumentation • Each instrumented file is saved as <file name>. <inst directory>. inst. c • The following files are saved in the instrumentation directory: – Instrumentation. Init. c, containing the new main function for the instrumented program – project. History file, containing information for the parser and for CCombine – a configuration file named <file name>. c. config for each instrumented file, containing the instrumented points used by the GUI
Compiling and Linking % cc -64 -c file 1. Context 1. inst. c % cc -64 -c file 2. Context 1. inst. c % cc -64 -c Context 1/Instrumentation. Init. c % cc -64 -o app file 1. Context 1. inst. o file 2. Context 2. inst. o Instrumentation. Init. o /usr/local/Sv. Pablo/lib/c. Trace. o /usr/local/Sv. Pablo/lib/sv. Pablo. Lib_MPI. o -L/usr/lib 64/libmpi. so -lmpi
- Slides: 24