Differences between revisions 2 and 3
Revision 2 as of 2017-01-03 23:36:49
Size: 1979
Editor: MalteHelmert
Comment:
Revision 3 as of 2017-01-03 23:42:21
Size: 2020
Editor: MalteHelmert
Comment:
Deletions are marked like this. Additions are marked like this.
Line 18: Line 18:
valgrind --tool=callgrind --callgrind-out-file=callgrind.out --dump-instr=yes --collect-jumps=yes ./builds/release64/bin/downward --search "astar(blind())" < output.sas valgrind --tool=callgrind --callgrind-out-file=callgrind.out \
    
--dump-instr=yes --collect-jumps=yes \
   
./builds/release64/bin/downward --search "astar(blind())" < output.sas
Line 54: Line 56:
sudo install -m 755 qcachegrind/qcachegrind /usr/local/bin
sudo install -m 644 qcachegrind/qcachegrind.desktop /local/share/applications/
sudo install -m 644 kcachegrind/hi32-app-kcachegrind.png /usr/local/share/icons/hicolor/32x32/apps/kcachegrind.png
sudo install -m 644 kcachegrind/hi48-app-kcachegrind.png /usr/local/share/icons/hicolor/48x48/apps/kcachegrind.png
sudo install -m 755 qcachegrind/qcachegrind /usr/local/bin/
sudo install -m 644 qcachegrind/qcachegrind.desktop \
     /usr
/local/share/applications/
sudo install -m 644 kcachegrind/hi32-app-kcachegrind.png \
   
/usr/local/share/icons/hicolor/32x32/apps/kcachegrind.png
sudo install -m 644 kcachegrind/hi48-app-kcachegrind.png \
    
/usr/local/share/icons/hicolor/48x48/apps/kcachegrind.png

Back to developer page.

Profiling

Profiling Running Time

Here is an example of how to run the callgrind tool of valgrind to profile the search component.

To set up, run the translator component:

./fast-downward.py --translate PROBLEM.PDDL

To profile, run the search component manually under valgrind (substitute the appropriate build and search options):

valgrind --tool=callgrind --callgrind-out-file=callgrind.out \
    --dump-instr=yes --collect-jumps=yes \
    ./builds/release64/bin/downward --search "astar(blind())" < output.sas

To browse the results of profiling:

# either this:
kcachegrind callgrind.out

# or this:
qcachegrind callgrind.out

Installing QCacheGrind

QCacheGrind is KCacheGrind without the KDE bindings and is part of the same source archive as KCacheGrind. You may want to try it if you would rather not install all the KDE dependencies that KCacheGrind brings in.

To download and build QCacheGrind:

sudo apt-get install qt5-default graphviz
## Download December 2016 release. Alternatively, check
## https://github.com/KDE/kcachegrind/releases for something more recent.
wget https://github.com/KDE/kcachegrind/archive/v16.12.0.tar.gz
tar xvzf v16.12.0.tar.gz
cd kcachegrind-16.12.0
qmake && make -j4

Then copy the executable qcachegrind/qcachegrind to your preferred place, for example:

cp qcachegrind/qcachegrind ~/bin/

All other files can be deleted. Alternatively, for a system-wide install that includes metadata for the desktop:

sudo install -m 755 qcachegrind/qcachegrind /usr/local/bin/
sudo install -m 644 qcachegrind/qcachegrind.desktop \
     /usr/local/share/applications/
sudo install -m 644 kcachegrind/hi32-app-kcachegrind.png \
    /usr/local/share/icons/hicolor/32x32/apps/kcachegrind.png
sudo install -m 644 kcachegrind/hi48-app-kcachegrind.png \
    /usr/local/share/icons/hicolor/48x48/apps/kcachegrind.png

FastDownward: ForDevelopers/Profiling (last edited 2019-01-18 15:05:28 by JendrikSeipp)