Skip to content

Fix minidump generation - missing IP for exception stack frames - #115025

Merged
mikem8361 merged 2 commits into
dotnet:mainfrom
mikem8361:fix_dump_gen
Apr 25, 2025
Merged

Fix minidump generation - missing IP for exception stack frames#115025
mikem8361 merged 2 commits into
dotnet:mainfrom
mikem8361:fix_dump_gen

Conversation

@mikem8361

Copy link
Copy Markdown
Contributor

This was caused by changes in PR #114582 where Exception::GetStackTrace called GetThread() which throws an error exception in the DAC. Changed the enummem.cpp code in ClrDataAccess::DumpManagedExcepObject() to call the GetStackTrace overload that allows a NULL pCurrentThread parameter to be passed.

This was caused by changes in PR dotnet#114582 where
Exception::GetStackTrace called GetThread() which throws an error exception in the
DAC. Changed the enummem.cpp code in ClrDataAccess::DumpManagedExcepObject() to call
the GetStackTrace overload that allows a NULL pCurrentThread parameter to be passed.
@mikem8361
mikem8361 requested a review from davidwrighton April 24, 2025 23:05
@mikem8361 mikem8361 self-assigned this Apr 24, 2025
Copilot AI review requested due to automatic review settings April 24, 2025 23:05

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

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 fixes an issue in minidump generation by updating the call to GetStackTrace to use the overload that accepts a NULL pCurrentThread parameter, ensuring that exception stack frames include the proper IP.

  • Updated call to GetStackTrace to include additional parameters
  • Ensured compatibility with changes in the DAC error handling

@mikem8361

Copy link
Copy Markdown
Contributor Author

@hoyosjs I found the dump generation problem that were caused the SOS tests to fail in dotnet/diagnostics#5461

@dotnet-policy-service

Copy link
Copy Markdown
Contributor

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

@mikem8361
mikem8361 merged commit 143bd05 into dotnet:main Apr 25, 2025
@mikem8361
mikem8361 deleted the fix_dump_gen branch April 25, 2025 06:14
@github-actions github-actions Bot locked and limited conversation to collaborators May 25, 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.

3 participants