Callgrind Performance Profiling

Everything about development and the OpenMW source code.
Locked
User avatar
lgromanowski
Site Admin
Posts: 1150
Joined: 05 Aug 2011, 22:21
Location: Wroclaw, Poland
Github profile: https://github.com/lgromanowski
Contact:

Callgrind Performance Profiling

Post by lgromanowski » 13 Aug 2011, 20:12

EmbraceUnity wrote: Just thought I would give a brief tutorial of a very slick open source performance profiler I found out about on a KDE blog. It will be good for future reference.

The instructions I based my example on are here: http://wiki.services.openoffice.org/wiki/Callgrind

Basically, after you install valgrind kcachegrind graphviz, open up a console and navigate to your OpenMW/Build folder and type the following:

Code: Select all

valgrind --tool=callgrind ./openmw
Then let that run and do whatever test scenario you'd like to test (console scripts, GUI, sounds, whatever). After you esc out of openmw it should create a file with a name like "callgrind.out.pid"

In the console type:

Code: Select all

kcachegrind callgrind.out.pid.xxxx
You can get more specific, and only start callgrind at the moment you wish to test, so that you dont test the load logic, but this is the basic example of what it created for me:

<!-- ia0 -->Kcachegrind.jpg<!-- ia0 -->
nicolay wrote: VERY nice! Just tried this myself, and I can see this becoming a very valuable tool for optimizing later on.

Actually I've have been looking for a graphical and easy-to-use profiler like this, so thanks for this link.
Star-Demon wrote: That looks really cool. If you don't mind, can you post some basic links so I can learn a little about that?

BTW: Go KDE! How's things since 4.0?
sir_herrbatka wrote:
BTW: Go KDE! How's things since 4.0?
Two steps forward, one step backward - slowly forward in result but 4.4.5 is just great and I will stick to that on netbook (ubuntu LTS) while I have 4.5 on desktop (pclinuxos).

Only drawback is that 4.5 is faster than 4.4.5.
EmbraceUnity wrote: Yea, it took awhile for 4.x to catch up, but now it is seriously like KDE and GNOME are in different centuries. I'll leave you to decide which one is in which.
best regards,
Lukasz

Locked

Who is online

Users browsing this forum: Yahoo [Bot] and 1 guest