Conversation
…cenarios (dotnet#112403)" This reverts commit bdd0dae.
Contributor
|
Tagging subscribers to this area: @agocke, @dotnet/gc |
Contributor
There was a problem hiding this comment.
Pull request overview
This pull request reverts PR #112403, which introduced logic changes for handling pin promotion/demotion in the GC (Garbage Collector) that caused hangs in some scenarios. The revert removes the problematic optimization and restores the previous working implementation.
Changes:
- Reverts pin promotion decision logic to use simpler inline checks instead of extracted helper functions
- Restores the
demote_gen1_pflag for non-regions builds, replacingdecide_promote_gen1_pins_p - Inlines the
attribute_pin_higher_gen_alloclogic back into call sites - Simplifies
decide_on_demotion_pin_survfunction signature and implementation for regions builds
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| src/coreclr/gc/gcpriv.h | Reverts function signatures and field declarations - removes decide_promote_gen1_pins_p, restores demote_gen1_p, removes helper function declarations |
| src/coreclr/gc/gc.cpp | Reverts implementation changes - removes extracted helper functions, inlines pin allocation attribution logic at call sites, restores original demotion decision logic, includes minor whitespace corrections |
This was referenced Feb 4, 2026
mangod9
approved these changes
Feb 4, 2026
This was referenced Feb 9, 2026
Member
Author
|
/backport to release/10.0 |
Contributor
|
Started backporting to |
4 tasks
agocke
added a commit
that referenced
this pull request
Feb 19, 2026
Backport of #123966 to release/10.0 /cc @agocke ## Customer Impact - [X] Customer reported - [ ] Found internally Customer reported that they saw GC deadlocks after upgrading to .NET 10. This PR is the cause. After revert, deadlocks went away. ## Regression - [X] Yes - [ ] No ## Testing A private build was shared with the customer and confirmed that this PR was the cause of the regression. ## Risk Low. This will return us to the .NET 9 state. This PR was intended to work around issues with high pinning scenarios, but the previous state was well-understood and acceptable. Co-authored-by: Andy Gocke <andy@commentout.net>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Reverts: #112403
This change appears to cause hangs in some cases. This may cause some performance loss in high pinning scenarios.