I'm trying to understand how a program's performance changes when run with different options—I have a factor of 1.8 I'd like to explain. I've been doing profiling with [valgrind]'s callgrind
tool and using kcachegrind to visualize the results.
But I'd really like to look at differences. I found the cg_diff
program but it doesn't work with callgrind profiles, only with cachegrind profiles, which are too expensive for me to gather.
Does anybody know of tools for visualizing the difference between two profiles?
Is there a tool to examine the difference of two callgrind/valgrind profiles?
Asked Answered
Gosh, Norman, we've been here before :) Let's see, 1/1.8 = 56%, so if you take about 10 stack samples of each, on about 44%+/- of the slow one's samples, you're going to see one or a few lines of code you don't see so much on the fast one's. If it doesn't work, let me know. –
Gerdagerdeen
Specifically, number of samples that show the explanation should be a binomial distribution, with mean = 10*.44 = 4.4, and standard deviation = sqrt(10 * .44 * .56) = 1.6, so likely between 3 and 6 samples :-) –
Gerdagerdeen
I'm on Windows, not linux, but if the programs are in C or C++, zip me the files and I'll be happy to demonstrate. Cheers. –
Gerdagerdeen
@Mike: I'm stuck in the ghetto: Objective Caml. I'd kill for a stack-sampling profiler. –
Poop
Wow, you really are. Even so, it's got a debugger that can display stack traces. Like most half-baked systems, they don't tell you how to interrupt it. Nevertheless you may be able to, by Ctrl-C or whatever. Also pstack or lsstack might work. I know it's getting away from your original question a bit, but that's the beeline I make. Get them stack samples. And good luck. –
Gerdagerdeen
I forgot to mention Zoom, a linux stack-sampler on compiled code. Probably wouldn't work on OCaml, since what they mean by "compile" seems to be "gen byte code". (My only little critique of Zoom is a) it costs money, and b) they're in the we-need-lots-of-samples party.) –
Gerdagerdeen
I just installed OCaml for Windows. If you care to zip me the files I can give it a shot. –
Gerdagerdeen
There is a tool for the results of cachegrind, cg_diff. But no tool for callgrind.
© 2022 - 2024 — McMap. All rights reserved.