HP-UX Reference (11i v2 07/12) - 1 User Commands A-M (vol 1)
c
caliper(1)
For Integrity Systems Only
caliper(1)
Caliper 4.3 Caliper 4.3
(Requires Optional HP Caliper Software)
caliper pmu_trace --sampling-spec=10000,0,CPU_CYCLES
program
This will run program, measuring and reporting the number of Itanium instructions executed
(IA64_INST_RETIRED), the number of nops executed (NOPS_RETIRED) and the number of CPU
cycles (CPU_CYCLES) every 10,000 cpu cycles (with no sampling variation. The
pmu_trace meas-
urement default is to sample every 50,000,000 cpu cycles.
CALIPER_OPTS="--module-exclude=/usr/lib/" caliper fprof
program
This will run program, measuring and reporting a flat profile of sampled instruction addresses,
excluding all system libraries.
caliper cstack program
This will run program, measuring and reporting a call stack profile by periodically sampling the appli-
cation program counter and each of its thread’s call stacks.
caliper report --detail=0 fprof
This will re-report the last fprof measurement run with all functions included in the report (no
matter how little CPU time they used).
caliper info --detail=all L2
This will produce an information report including all details on all cpu events with "L2" in name.
caliper info -r itlb
This will produce an information report on the itlb measurement report.
caliper scgprof -w -e10
This will collect all activity across all CPUs in the system for a duration of 10 seconds, producing a
sample-based call graph report.
caliper ecount -pall \
sh -c ’/usr/bin/ls; /usr/bin/echo done’
This will measure /usr/bin/sh , /usr/bin/sl , and /usr/bin/echo
executions.
caliper ecount --process=ls:echo \
sh -c ’/usr/bin/ls; /usr/bin/echo done’
This will measure both /usr/bin/ls and /usr/bin/echo processes.
caliper ecount --process=*[ho] \
sh -c ’/usr/bin/ls; /usr/bin/echo done’
This will measure both /usr/bin/sh and /usr/bin/echo
processes.
caliper ecount --process=’(arg1,regexp)tmp$’ \
sh -c ’/usr/bin/ls /var/tmp; /usr/bin/echo tmp listed’
This will measure both the /usr/bin/ls and /usr/bin/echo
processes, since the regular
expression
tmp$ matches their argument 1.
caliper fprof -d fprof.db1 cc -g himom.c ;
caliper fprof -d fprof.db2 cc -O himom.c ;
caliper diff -o output fprof.db1 fprof.db2
This will create a report with the difference between the data collected in the two collection runs.
caliper advise DB1 DB2
This will analyze the data in HP Caliper databases DB1 and DB2, and make suggestions for perfor-
mance improvements.
HP-UX ONLY EXAMPLES
caliper cgprof program
This will run program, measuring and reporting an extended gprof-like call graph profile.
caliper cgprof --html=HTML program
This performs the same cgprof performance measurement as the previous example but produces an
HTML-formatted report in directory HTML for browsing.
HP-UX 11i Version 2: December 2007 Update − 21 − Hewlett-Packard Company 111