-
Notifications
You must be signed in to change notification settings - Fork 613
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
weblist gives wrong flat count #720
Comments
Plain text of the HTML from Pprof listing.zip to see L268 referred above without opening the file:
|
I notice that there are separate implementations of computing flat and cum counts in list vs weblist. If I understand correctly, the values in I wonder if |
@prattmic Using the following commands to reproduce the problem, and check if
I get the following assembly:
Given the absense of the |
I came across this issue a couple of days ago and I think I've got an idea about what's going on here. There's a setup description and minimal replication here. A discussion back on #628 points to a section of code that accumulates the samples for a given address. I suspect, but have not been able to fully verify, that this accumulation for I've tried to fix it, but have been running into issues where a homebuilt |
Initially filed at golang/go#52000 by @fumin. Moving here as this seems to be an issue in pprof.
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
Yes.
What operating system and processor architecture are you using (
go env
)?go env
OutputWhat did you do?
I profiled the standard library's
png.Encode
function and looked at this attached profile:png_encode.zip
I then ran both
weblist
andlist
on thepng.filter
function.What did you expect to see?
I expect both
weblist
andlist
to show the same result.What did you see instead?
I saw
list
showing the correct result, with the sum of theflat
time ofpng.abs8
inpng.filter
tallying with the total time spent onpng.abs8
.In particular, the below log shows that
png.abs8
took 1.56 seconds in total.Adding the time spent on
png.abs8
inpng.filter
also shows the same 1.56 seconds.However,
weblist
shows the wrong result, it seems to exagerate the result.Pprof listing.zip
For example, on line 268,
list
shows only 80ms spent, whereasweblist
shows 360ms spent.The text was updated successfully, but these errors were encountered: