[cairo] Some performance investigations

Owen Taylor otaylor at redhat.com
Thu Nov 9 11:36:13 PST 2006


On Thu, 2006-11-09 at 11:17 -0800, Carl Worth wrote:

> [*] I'm really loving "valgrind --tool=callgrind" now---there's so
> much information that's good for algorithmic analysis that the
> statistical sampling profilers just don't capture. (And there's a lot
> of stuff that callgrind can't capture like system-wide, multi-process
> effects.)

callgrind is a cool tool indeed, but you have to be a bit careful
with it:

 - Estimation of execution times even for pure CPU work can be
   way off; I've seen cases where a chunk of my program that
   is taking 30% of the wall time shows up as 70% of the time
   in callgrind and similar.

 - It (obviously) neglects anything but CPU work, so if your
   program is spending time in X, in disk IO, etc, the information
   is useless.

It's most useful (as it sounds like you are using it) for finding
when your algorithm is doing something unexpected ... "why is
this function getting called 10,000 times?"

				- Owen







More information about the cairo mailing list