PowerSleuth is a tool that profiles your applications power/performance and phase behavior.
See uart/power_sleuth for more information.
PowerSleuth is built around ScarPhase. See scarphase for more instructions.
git clone https://github.com/uart/scarphase.git
cd scarphase
git submodule update --init
cmake .
make
git clone https://github.com/uart/powersleuth.git
cd powersleuth
export PYTHONPATH=/path/to/scarphase
./powersleuth -h
usage: ./powersleuth <command> [<args>]
Commands:
profile Profile stuff
plot Plot power and performance data
dump Dump power and performance data
show Show stuff
raw-dump Dump raw performance counter data
simpoint Find simpoints
refine Refine data
raw-plot Plot raw performance counter data
See './powersleuth help <command>' for more information.
This profiles and finds runtime phases in gcc from SPEC2006, with input 166.i. The profile is saved in gcc.profile and is used in the succeeding examples to plot and dump gcc's phases.
./powersleuth profile \
--scarphase-conf configs/scarphase/example0.conf \
--counter-conf configs/intel/nehalem/i7-920.counters.json \
--counter-limit=3 \
gcc.profile \
-- /path/to/gcc 166.i -o 166.s
./powersleuth profile
- scarphase command--scarphase-conf configs/scarphase/example0.conf
- contains the configuration settings for the ScarPhase library.--counter-conf configs/counters/list0.json
- a list of performance counter to sample--counter-limit
- number of available hardware performance countersgcc.profile
- output file-- gcc 166.i -o 166.s
- command to run (use absolute paths)
This plots the performance data and the detected phases from the example above.
./powersleuth plot power-heatmap \
--cpu-info configs/intel/nehalem/i7-920.cfg \
--profile-frequency 2.4 --thread 0 gcc.profile
./powersleuth plot
- scarphase commandpower-heatmap
- subcommand: plots power heatmap--cpu-info configs/intel/nehalem/i7-920.cfg
- config for the processor--profile-frequency 2.4
- the frequency the profiling was done at--thread 0
- which threadgcc.profile
- profile from example 1
- Power-Sleuth: A Tool for Investigating your Program's Power Behavior Vasileios Spiliopoulos, Andreas Sembrant and Stefanos Kaxiras. In International Symposium on Modeling, Analysis and Simulation of Computer and Telecommunication Systems (MASCOTS'12)