-
Notifications
You must be signed in to change notification settings - Fork 18k
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
cmd/compile: bad inlining informations in debug_info with DWARFv5 on tip #72821
Comments
cc @golang/compiler |
cc @thanm |
Thanks. I see the problem -- fix en route. |
What's happening in this bug is that we're trying to emit the hi/lo PC values for a given inlined func using I am going to fix this bug by changing the compiler to unconditionally use Background: prior to this point, if a given inlined function body had a single contiguous range, we'd pick an abbrev entry for it with explicit With DWARF 5, range info is written to the Note: we should at some point consider applying this same strategy to lexical scopes, since we can probably reap some of the same benefits there as well. @aarzilli please weigh in if you can see any issues with moving in this direction. |
Change https://go.dev/cl/657175 mentions this issue: |
When compiling a simple hello world program the DIE for runtime.main contains the following inlined subroutine entry:
The abstract origin is:
but according to the inlined subroutine entry this inlining is 657 bytes long and starts at the entry point of runtime.main (neither sounds plausible for atomic.Load).
Calling dwarf.(*Data).Ranges on the same entry returns the same values, so this shouldn't be an GNU objdump bug.
cc @thanm
The text was updated successfully, but these errors were encountered: