Feature/cdac contract renumber to v1 - #131855
Merged
noahfalk merged 1 commit intoAug 6, 2026
Merged
Conversation
|
Azure Pipelines: Successfully started running 5 pipeline(s). 11 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
|
Tagging subscribers to this area: @steveisok, @tommcdon, @dotnet/dotnet-diag |
Contributor
There was a problem hiding this comment.
Pull request overview
Renumbers cDAC contracts to start from c1 by folding previously-development-only contract versions into the remaining version(s), updating CoreCLR contract advertisements/registrations, tests, and the authoritative data contract docs accordingly.
Changes:
- Consolidate PrecodeStubs/ExecutionManager/DebugInfo implementations to
c1and delete superseded versioned implementations/helpers. - Update CoreCLR contract registrations/advertisements and align unit/integration tests to the new version set.
- Refresh
docs/design/datacontracts/*specs and descriptor-meaning/override metadata to match the new contract shapes.
Reviewed changes
Copilot reviewed 28 out of 28 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| src/native/managed/cdac/tools/CdacUsageGraph/tests/CdacUsageGraph.Tests/UsageWalkerIntegrationTests.cs | Updates usage-graph integration assertions for renumbered contract versions/fields. |
| src/native/managed/cdac/tests/UnitTests/PrecodeStubsTests.cs | Collapses multi-version PrecodeStubs tests to c1 and updates mock descriptor layout accordingly. |
| src/native/managed/cdac/tests/UnitTests/MockDescriptors/MockDescriptors.ExecutionManager.cs | Removes c2 nibblemap builder selection; c1 now uses the remaining builder. |
| src/native/managed/cdac/tests/UnitTests/FunctionTableAccessTests.cs | Simplifies test matrix to only run against c1. |
| src/native/managed/cdac/tests/UnitTests/ExecutionManager/NibbleMapTests.cs | Removes linear-lookup tests and reorients tests to helpers + constant-lookup behavior. |
| src/native/managed/cdac/tests/UnitTests/ExecutionManager/NibbleMapTestBuilder.cs | Removes the *_2 builder and updates *_1 to emit constant-lookup pointer encoding. |
| src/native/managed/cdac/tests/UnitTests/ExecutionManager/ExecutionManagerTests.cs | Updates version-driven tests to only cover c1. |
| src/native/managed/cdac/tests/UnitTests/ContractDescriptor/TargetTests.SubDescriptors.cs | Adjusts required-contract filtering to work with the new contract->version map. |
| src/native/managed/cdac/tests/UnitTests/ContractDescriptor/TargetTests.cs | Switches required-contract list to a name->version dictionary (keeps StressLog at c2). |
| src/native/managed/cdac/Microsoft.Diagnostics.DataContractReader.Contracts/Data/StubPrecodeData.cs | Removes StubPrecodeData_1; keeps StubPrecodeData_2 as the sole representation. |
| src/native/managed/cdac/Microsoft.Diagnostics.DataContractReader.Contracts/Data/PrecodeMachineDescriptor.cs | Removes older-version-only fields and standardizes on the newer descriptor set. |
| src/native/managed/cdac/Microsoft.Diagnostics.DataContractReader.Contracts/CoreCLRContracts.cs | Registers only the remaining contract versions (c1, plus StressLog c2). |
| src/native/managed/cdac/Microsoft.Diagnostics.DataContractReader.Contracts/Contracts/PrecodeStubs_Common.cs | Simplifies the common precode-stubs abstraction by removing the stub-data generic. |
| src/native/managed/cdac/Microsoft.Diagnostics.DataContractReader.Contracts/Contracts/PrecodeStubs_1.cs | Moves c1 behavior to the newer precode-type detection + interpreter handling. |
| src/native/managed/cdac/Microsoft.Diagnostics.DataContractReader.Contracts/Contracts/PrecodeStubs_2.cs | Deleted (version consolidation). |
| src/native/managed/cdac/Microsoft.Diagnostics.DataContractReader.Contracts/Contracts/PrecodeStubs_3.cs | Deleted (version consolidation). |
| src/native/managed/cdac/Microsoft.Diagnostics.DataContractReader.Contracts/Contracts/ExecutionManager/Helpers/NibbleMapLinearLookup.cs | Deleted (no longer used after consolidation). |
| src/native/managed/cdac/Microsoft.Diagnostics.DataContractReader.Contracts/Contracts/ExecutionManager/Helpers/NibbleMapConstantLookup.cs | Updated comments; remains the nibblemap algorithm used by c1. |
| src/native/managed/cdac/Microsoft.Diagnostics.DataContractReader.Contracts/Contracts/ExecutionManager/ExecutionManager_1.cs | Switches c1 to use NibbleMapConstantLookup. |
| src/native/managed/cdac/Microsoft.Diagnostics.DataContractReader.Contracts/Contracts/ExecutionManager/ExecutionManager_2.cs | Deleted (version consolidation). |
| src/native/managed/cdac/Microsoft.Diagnostics.DataContractReader.Contracts/Contracts/DebugInfo/DebugInfo_1.cs | Consolidates DebugInfo behavior to the newer header/chunk decoding and APIs. |
| src/native/managed/cdac/Microsoft.Diagnostics.DataContractReader.Contracts/Contracts/DebugInfo/DebugInfo_2.cs | Deleted (version consolidation). |
| src/coreclr/vm/datadescriptor/datadescriptor.inc | Updates advertised contract versions to match the new c1 set (StressLog stays c2). |
| docs/design/datacontracts/PrecodeStubs.md | Updates the authoritative PrecodeStubs spec to the consolidated c1 shape/algorithm. |
| docs/design/datacontracts/ExecutionManager.md | Updates nibblemap documentation to describe the constant-lookup algorithm as c1. |
| docs/design/datacontracts/DebugInfo.md | Updates DebugInfo spec to a single c1 description (fat/slim header, vars, async). |
| docs/design/datacontracts/data-descriptor-overrides.json | Removes now-unneeded suppressions for retired contract versions. |
| docs/design/datacontracts/data-descriptor-meanings.json | Removes version-qualified phrasing and updates meanings to match consolidated contracts. |
Suppressed comments (1)
src/native/managed/cdac/Microsoft.Diagnostics.DataContractReader.Contracts/Contracts/PrecodeStubs_1.cs:82
- TryGetKnownPrecodeType returns KnownPrecodeType.DynamicHelper here, but PrecodeStubsCommon.GetPrecodeFromEntryPoint() doesn't handle DynamicHelper (or UMEntry) and will throw InvalidOperationException if GetMethodDescFromStubAddress is called for such a precode. Either implement handling for these precode types in PrecodeStubsCommon (and provide GetMethodDesc behavior), or avoid reporting them as "known" until they are supported.
else if (precodeMachineDescriptor.DynamicHelperPrecodeType is byte compareByte5 && compareByte5 == exactPrecodeType)
{
return KnownPrecodeType.DynamicHelper;
}
This was referenced Aug 5, 2026
A previous PR removed some unneeded contract versions that got created during .NET 11 development. This followup change renumbers so that the contract versions start at 1 for consistency.
noahfalk
force-pushed
the
feature/cdac-contract-renumber-to-v1
branch
from
August 5, 2026 21:20
63bf45a to
a5b6f10
Compare
noahfalk
marked this pull request as ready for review
August 5, 2026 21:22
|
Azure Pipelines: Successfully started running 5 pipeline(s). 11 pipeline(s) were filtered out due to trigger conditions. There may be pipelines that require an authorized user to comment /azp run to run. |
hoyosjs
approved these changes
Aug 5, 2026
max-charlamb
approved these changes
Aug 5, 2026
noahfalk
enabled auto-merge (squash)
August 5, 2026 22:26
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.
Follow up to #131790 to renumber the contracts starting from 1.
This PR includes all the commits in the previous one. As soon as 131790 gets merged I'll rebase and squash so this becomes a single commit.