-
Notifications
You must be signed in to change notification settings - Fork 17
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
Evaluate writing out a MemoryInfoListStream #8
Comments
If someone writes a useful parser for |
@luser Would |
That doesn't quite feel like the right place for it, since currently n.b.: @Gankra implemented stackwalker parsing of this along with a unified interface atop that + |
I agree, I was asking on the off-chance that others didn't agree with my thought so it'd be simpler :) Thanks for the info, I was aware of the existing impl. I was just going to move it somewhere common and maybe slightly clean up the interface so that it could be used in minidump-writer! |
Any suggestion on crate name/location? Alternatively, maybe we could contribute to the |
Contributing to an external crate sounds like a good idea if the crate is sufficiently widespread and useful. We parse |
Yeah, I figured with the other procfs needs we have, it'd be great to take advantage of |
The |
Excellent! |
I'm currently waiting (patiently, there's no rush) for |
|
@eminence thanks for chiming in with an update! I will set a reminder to check on things in a week. |
This makes it easier for consumers to read the minidumps, rather than needing to parse linux-specific information. Closes rust-minidump#8.
This makes it easier for consumers to read the minidumps, rather than needing to parse linux-specific information. Closes rust-minidump#8.
To improve stack walking heuristics we'd like to validate ambiguous instruction pointers by checking if they fall within an executable reason. On Windows this is already possible because windbg.dll populates the
MemoryInfoListStream
with the whole state of the process' memory when it snapshots it. On Linux we currently have/proc/self/maps
which contains the required information but we'd have to parse it in the stackwalker to yield the same information. Alternatively we might try and populate theMemoryInfoListStream
on Linux too in order to be able to use the same code across different platforms.Populating the stream should be relatively simple, info regarding the header and entries are readily available. The biggset issue is that the
AllocationProtect
,State
,Protect
andType
fields are supposed to contain Windows-specific constants. There's two ways to tackle this: either we use those fields to store Linux-specific constants - but that would defeat the purpose of having identical code for all platforms in the stack walker - or we map them to their closest Windows equivalents. Interestingly crashpad does the latter for fuchsia but it does not populate the stream on Linux and macOS.The text was updated successfully, but these errors were encountered: