Uh oh!
There was an error while loading. Please reload this page.
Implement cDAC DACDBI GetObjectFields and rework signature to UINT64 - #128179
Conversation
Co-authored-by: rcj1 <77995559+rcj1@users.noreply.github.com>
Tagging subscribers to this area: @steveisok, @tommcdon, @dotnet/dotnet-diag |
There was a problem hiding this comment.
Pull request overview
This PR updates the DAC/DBI GetObjectFields pathway: it implements GetObjectFields in the managed cDAC DacDbiImpl using RuntimeTypeSystem/metadata contracts, and it changes the native IDacDbiInterface::GetObjectFields signature to take a UINT64 (method table pointer) instead of COR_TYPEID (since only token1 was used).
Changes:
- Implemented managed cDAC
DacDbiImpl.GetObjectFieldsincluding field offsets and field type resolution via contracts + ECMA metadata decoding. - Updated native DACDBI interface and call site to pass a
UINT64id (id.token1) instead of a fullCOR_TYPEID. - Added dump-based tests covering
GetObjectFieldssuccess and key error/query scenarios.
Show a summary per file
| File | Description |
|---|---|
| src/native/managed/cdac/tests/DumpTests/DacDbi/DacDbiObjectDumpTests.cs | Adds dump-based tests for GetObjectFields behavior and contract cross-validation. |
| src/native/managed/cdac/Microsoft.Diagnostics.DataContractReader.Legacy/Dbi/IDacDbiInterface.cs | Updates managed COM projection signature for GetObjectFields to take ulong. |
| src/native/managed/cdac/Microsoft.Diagnostics.DataContractReader.Legacy/Dbi/DacDbiImpl.cs | Implements GetObjectFields in managed cDAC using runtime contracts + metadata signature decoding. |
| src/native/managed/cdac/Microsoft.Diagnostics.DataContractReader.Contracts/RuntimeTypeSystemHelpers/ExtensionMethods.cs | Changes helper extension class visibility to public to enable cross-assembly use. |
| src/coreclr/inc/dacdbi.idl | Changes native IDacDbiInterface::GetObjectFields parameter type to UINT64. |
| src/coreclr/debug/inc/dacdbiinterface.h | Updates the C++ interface signature accordingly. |
| src/coreclr/debug/di/process.cpp | Adjusts CordbProcess::GetTypeFields to pass id.token1. |
| src/coreclr/debug/daccess/dacdbiimpl.h | Updates DAC implementation declaration to match new signature. |
| src/coreclr/debug/daccess/dacdbiimpl.cpp | Updates DAC implementation definition to match new signature and adjusts related comment. |
Copilot's findings
- Files reviewed: 9/9 changed files
- Comments generated: 2
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
rcj1
commented
May 22, 2026
/ba-g unrelated libraries failure |
Implements
GetObjectFieldsin the managed cDAC DAC-DBI layer usingRuntimeTypeSystemcontracts, and reworks the native interface to take aUINT64instead ofCOR_TYPEID(onlytoken1was ever consumed).