Skip to content

Disable stacks on Debugger IPC events #114585

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

Merged
merged 4 commits into from
May 8, 2025

Conversation

tommcdon
Copy link
Member

We have received complaints from internal teams that app can crash when entering break state with Debugger IPC ETW events enabled. I was able to reproduce the issue by using perfview to enable .NET ETW events, F5 a .NET Core, and enter break state by hitting a breakpoint. The root issue is related to stackwalking on the Debugger IPC event causing a crash in the runtime. As the stack traces on Debugger IPC events is not useful in any production scenario, this PR disables the stackwalk on the IPC event.

@tommcdon tommcdon added this to the 10.0.0 milestone Apr 12, 2025
@tommcdon tommcdon requested review from noahfalk, hoyosjs and a team April 12, 2025 02:02
@tommcdon tommcdon self-assigned this Apr 12, 2025
@Copilot Copilot AI review requested due to automatic review settings April 12, 2025 02:02
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot wasn't able to review any files in this pull request.

Files not reviewed (1)
  • src/coreclr/vm/ClrEtwAllMeta.lst: Language not supported

Copy link
Contributor

Tagging subscribers to this area: @tommcdon
See info in area-owners.md if you want to be subscribed.

@noahfalk
Copy link
Member

The root issue is related to stackwalking on the Debugger IPC event causing a crash in the runtime

Do we know why it crashes? Its not obvious to me why a crash in stackwalking would only be a problem for debugger related ETW events rather than all ETW events.

@tommcdon
Copy link
Member Author

Do we know why it crashes?

Only that the stackwalker crashes on this one Debugger IPC event. Disabling the stackwalker successfully works around the issue. An internal partner team verified the fix.

@noahfalk
Copy link
Member

Adding a little bit of detail from chatting with Tom offline...

Although we don't have the dump handy any more to dig into the details, there was some evidence that the stackwalk failed because there was a breakpoint on the callstack. Debugger events are the only time we'd expect ETW events to find a breakpoint on the stack so we don't expect the stackwalking issue to be problematic anywhere else. A partner team also ran with the proposed fix for weeks and confirmed experimentally no other problems were showing up.

@tommcdon tommcdon merged commit b9d7c8b into dotnet:main May 8, 2025
95 checks passed
@github-actions github-actions bot locked and limited conversation to collaborators Jun 7, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants