]> git.ipfire.org Git - thirdparty/valgrind.git/commit
Callgrind: Fix printing of "Summary:" line in finish()
authorJosef Weidendorfer <Josef.Weidendorfer@gmx.de>
Tue, 11 Aug 2009 20:53:59 +0000 (20:53 +0000)
committerJosef Weidendorfer <Josef.Weidendorfer@gmx.de>
Tue, 11 Aug 2009 20:53:59 +0000 (20:53 +0000)
commit09d07a0b62fa4fb9a30f605da8282830c374f189
tree6a73d10a059c49fcee4a72f74af28632571df4bc
parentea40ea135afcc5cf9eac4d5f8f0d53d377a244de
Callgrind: Fix printing of "Summary:" line in finish()

The global cost counters, which are used for printing the
summary line, where zeroed before in init_exec_state(), called
by unwind_thread().

Stack unwinding (i.e. unwind_thread) is also done at instrumentation
state changes, and there, we want the cost counters to be zeroed
(was fix for bug 150606). Do this explicitly now.

PS: The correct fix for bug 150606 is not to zero the cost counters
(we do not really want this at instrumentation state changes), but
to store the current counter values in a "last_instr_state_on_cost"
counter, and use this as the global cost counter on enter for functions
which are left but were not detected to be entered.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@10782
callgrind/main.c
callgrind/threads.c