-
Notifications
You must be signed in to change notification settings - Fork 5.3k
Use nint instead of IntPtr in _RegisterFrozenSegment. #37029
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -353,7 +353,7 @@ public static long GetTotalMemory(bool forceFullCollection) | |||||||||||||||
| } | ||||||||||||||||
|
|
||||||||||||||||
| [DllImport(RuntimeHelpers.QCall, CharSet = CharSet.Unicode)] | ||||||||||||||||
| private static extern IntPtr _RegisterFrozenSegment(IntPtr sectionAddress, IntPtr sectionSize); | ||||||||||||||||
| private static extern IntPtr _RegisterFrozenSegment(IntPtr sectionAddress, nint sectionSize); | ||||||||||||||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The unmanaged size is using unsigned type for this, but fixing that would require changes in the code that looks up this API via private reflection.
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Right - the unmanaged code is using runtime/src/coreclr/src/vm/comutilnative.cpp Lines 1127 to 1133 in ab49e0f
I didn't want to actually change the managed type. Unless @mjsabby was OK with it. I assume that is the only user of this experimental feature, or are there others?
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Oops, I merged this -- perhaps there was an open question here? |
||||||||||||||||
|
|
||||||||||||||||
| [DllImport(RuntimeHelpers.QCall, CharSet = CharSet.Unicode)] | ||||||||||||||||
| private static extern void _UnregisterFrozenSegment(IntPtr segmentHandle); | ||||||||||||||||
|
|
||||||||||||||||
Uh oh!
There was an error while loading. Please reload this page.