-
Notifications
You must be signed in to change notification settings - Fork 4.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[cdac] start of RuntimeTypeSystem contract; implement GetMethodTableData SOS method #103444
Conversation
Tagging subscribers to this area: @tommcdon |
Need to reconcile with #99183 - I was on an older branch update updated and fixed the merge issues. Validated that |
src/native/managed/cdacreader/src/Contracts/Metadata.MethodTableFlags.cs
Outdated
Show resolved
Hide resolved
src/native/managed/cdacreader/src/Contracts/Metadata_1.MethodTableFlags.cs
Outdated
Show resolved
Hide resolved
src/native/managed/cdacreader/src/Contracts/Metadata_1.MethodTableFlags.cs
Outdated
Show resolved
Hide resolved
1. rename AttrClass data descriptor field to CorTypeAttr 2. fixup HasComponentSize / RawGetComponentSize comments and code 3. update "system.object" mock methodtable with more field values 4. update "system.string" mock methodtable with more field values
Co-authored-by: Elinor Fung <elfung@microsoft.com>
…ableFlags.cs Co-authored-by: Elinor Fung <elfung@microsoft.com>
I was asked to rename the contract from |
Naming suggestion: |
I prefer |
private readonly Target _target; | ||
private readonly TargetPointer _freeObjectMethodTablePointer; | ||
|
||
// TODO(cdac): we mutate this dictionary - copies of the Metadata_1 struct share this instance. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Support for invalidating our view of memory and re-reading to fill in the world should be a pretty soon now project, but I'm ok with having checking in the current state here, and fixing it later when we add that support.
src/native/managed/cdacreader/src/Contracts/RuntimeTypeSystem_1.cs
Outdated
Show resolved
Hide resolved
…1.cs Co-authored-by: Jan Kotas <jkotas@microsoft.com>
I now have unit tests for MethodTable validation and access for things that look like: Doing more testing is difficult until we have more query methods and data descriptors to mock something more interesting. I'd like to finish up with this PR and get into expanding the contract for the next SOS API (most likely |
Contributes to #99302
Also updates the existing DAC so that it does not store an
EEClass*
inDacpMethodTableData::Class
, but instead stores a pointer to the canonical method table. CorrespondinglyGetMethodTableForEEClass
now expects a canonical MethodTable.Also renamed
MethodTable::ContainsPointers
toContainsGCPointers
, (and corresponding flag and setter method); also updated gcenv for NativeAOT with the same renaming.Also changed the existing DAC so that
DacpMethodTableData::wNumVirtuals
andDacpMethodTableData::wNumVtableSlots
are always returned as 0. The cDAC Metadata contract does not expose the underlying infoverified that it works for at least one MethodTable by running some manual WinDbgX test
TODO: