Repository navigation
[cDAC] Remove vestigial IsPegged from HandleData - #130728
Merged
max-charlamb merged 2 commits intoJul 15, 2026
Merged
Conversation
Co-authored-by: Copilot <[email protected]> Copilot-Session: f2aa5dc4-0c99-43f0-af14-734143849c4a
|
Azure Pipelines: Successfully started running 5 pipeline(s). 10 pipeline(s) were filtered out due to trigger conditions. There may be pipelines that require an authorized user to comment /azp run to run. |
Contributor
There was a problem hiding this comment.
Pull request overview
This PR updates the cDAC GC contract surface by removing the (apparently unused) IsPegged member from the consumer-facing HandleData shape, while keeping the legacy SOS SOSHandleData.IsPegged field and explicitly forcing it to 0 for output parity.
Changes:
- Remove
IsPeggedfromHandleDatainIGCand stop populating it inGC_1handle enumeration. - Preserve
SOSHandleData.IsPeggedbut always emit0inSOSDacImpl, and tighten DEBUG parity checks to assert both implementations are0. - Update the GC contract specification doc to match the new handle construction logic.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| src/native/managed/cdac/Microsoft.Diagnostics.DataContractReader.Legacy/SOSDacImpl.cs | Always emits SOSHandleData.IsPegged = 0 and asserts pegging is always zero in DEBUG parity checks. |
| src/native/managed/cdac/Microsoft.Diagnostics.DataContractReader.Contracts/Contracts/GC/GC_1.cs | Stops setting the removed HandleData.IsPegged member during handle enumeration. |
| src/native/managed/cdac/Microsoft.Diagnostics.DataContractReader.Abstractions/Contracts/IGC.cs | Removes IsPegged from the public HandleData record struct signature. |
| docs/design/datacontracts/GC.md | Updates the contract algorithm snippet to no longer set IsPegged. |
Contributor
|
Tagging subscribers to this area: @steveisok, @tommcdon, @dotnet/dotnet-diag |
Co-authored-by: Copilot <[email protected]> Copilot-Session: f2aa5dc4-0c99-43f0-af14-734143849c4a
max-charlamb
marked this pull request as ready for review
July 15, 2026 00:56
|
Azure Pipelines: Successfully started running 5 pipeline(s). 10 pipeline(s) were filtered out due to trigger conditions. There may be pipelines that require an authorized user to comment /azp run to run. |
max-charlamb
enabled auto-merge (squash)
July 15, 2026 01:14
rcj1
approved these changes
Jul 15, 2026
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Summary
IsPeggedvalue from the consumer-facingHandleDatashape.SOSHandleData.IsPeggedfield and populate it with zero directly.This keeps the GC contract focused on values consumers can observe while preserving SOS output behavior.
Validation
dotnet build src\native\managed\cdac\cdac.slnx -c Debug -p:UseSharedCompilation=false /nr:falsedotnet test src\native\managed\cdac\tests\UnitTests\Microsoft.Diagnostics.DataContractReader.Tests.csproj -c Debug --no-build(2697 passed, 16 skipped)FullyQualifiedName~GCTestsrun (24 passed)Note
This PR was generated with the assistance of GitHub Copilot.