-
Notifications
You must be signed in to change notification settings - Fork 5.3k
[cDAC] X86 support HijackFrame #116829
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
[cDAC] X86 support HijackFrame #116829
Conversation
|
Tagging subscribers to this area: @steveisok, @dotnet/dotnet-diag |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds support for capturing and handling x86 hijack frames in the DataContractReader, extending both the data contract and the frame handler, plus updating the core runtime descriptor and documentation.
- Introduce
HijackArgsX86to read x86-specific hijack registers into a dictionary - Implement
HandleHijackFrameinX86FrameHandlerto restore registers and adjust the stack pointer - Extend
datadescriptor.hfor x86 register fields and update docs to include x86 HijackArgs
Reviewed Changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| src/native/managed/cdac/.../Data/Frames/HijackArgsX86.cs | Add x86-specific HijackArgsX86 data reader |
| src/native/managed/cdac/.../StackWalk/FrameHandling/X86FrameHandler.cs | Implement HandleHijackFrame for x86 |
| src/coreclr/debug/runtimeinfo/datadescriptor.h | Add x86 register fields (Edi, Esi, etc.) |
| docs/design/datacontracts/StackWalk.md | Update docs table to include x86 in HijackArgs entries |
Comments suppressed due to low confidence (2)
src/native/managed/cdac/Microsoft.Diagnostics.DataContractReader.Contracts/Contracts/StackWalk/FrameHandling/X86FrameHandler.cs:29
- No tests were added to verify the new x86 HijackFrame handling path; consider adding unit or integration tests to cover this functionality.
HijackArgsX86 args = _target.ProcessedData.GetOrAdd<HijackArgsX86>(frame.HijackArgsPtr);
docs/design/datacontracts/StackWalk.md:59
- [nitpick] The entry 'HijackArgs (arm64/x86)' may be ambiguous; consider splitting into separate rows for arm64 and x86 or clarifying platform-specific details.
| `HijackArgs` (arm64/x86) | For each register `r` saved in HijackArgs, `r` | Register names associated with stored register values |
Contributes to #114019
Verified using the following script to get a
[HijackFrame]on the stack: