diff options
author | Sean Gillespie <segilles@microsoft.com> | 2017-12-12 19:04:07 -0800 |
---|---|---|
committer | Sean Gillespie <segilles@microsoft.com> | 2017-12-12 19:04:07 -0800 |
commit | 8df01f50ca980ab8840124c74037782f75702032 (patch) | |
tree | 67632498038f401758197663622b1f32a4603eeb /src/vm/appdomain.cpp | |
parent | 3a295a078701f72edc18a4404cab7b7e1bc104c7 (diff) | |
download | coreclr-8df01f50ca980ab8840124c74037782f75702032.tar.gz coreclr-8df01f50ca980ab8840124c74037782f75702032.tar.bz2 coreclr-8df01f50ca980ab8840124c74037782f75702032.zip |
Revert "[Local GC] Move knowledge of overlapped I/O objects to the EE through four callbacks (#14982)"
This reverts commit c755e3b7f5d597c8d192675dbaaa337268d93f1c.
Diffstat (limited to 'src/vm/appdomain.cpp')
-rw-r--r-- | src/vm/appdomain.cpp | 38 |
1 files changed, 1 insertions, 37 deletions
diff --git a/src/vm/appdomain.cpp b/src/vm/appdomain.cpp index 07e3280342..370847c9a2 100644 --- a/src/vm/appdomain.cpp +++ b/src/vm/appdomain.cpp @@ -9053,43 +9053,7 @@ void AppDomain::HandleAsyncPinHandles() // 4. Then we can delete all AsyncPinHandle marked with READYTOCLEAN. IGCHandleStore *pBucketInDefault = SystemDomain::System()->DefaultDomain()->m_handleStore; - auto clearIfComplete = [](Object* object) - { - LIMITED_METHOD_CONTRACT; - - assert(object != nullptr); - if (object->GetGCSafeMethodTable() != g_pOverlappedDataClass) - { - return; - } - - OVERLAPPEDDATAREF overlapped = (OVERLAPPEDDATAREF)(ObjectToOBJECTREF((Object*)object)); - if (overlapped->HasCompleted()) - { - // IO has finished. We don't need to pin the user buffer any longer. - overlapped->m_userObject = NULL; - } - - BashMTForPinnedObject(ObjectToOBJECTREF(object)); - }; - - auto setHandle = [](Object* object, OBJECTHANDLE handle) - { - LIMITED_METHOD_CONTRACT; - - assert(object != nullptr); - assert(handle); - - if (object->GetGCSafeMethodTable() != g_pOverlappedDataClass) - { - return; - } - - OverlappedDataObject* overlapped = (OverlappedDataObject*)object; - overlapped->m_pinSelf = handle; - }; - - pBucket->RelocateAsyncPinnedHandles(pBucketInDefault, clearIfComplete, setHandle); + pBucket->RelocateAsyncPinnedHandles(pBucketInDefault); OverlappedDataObject::RequestCleanup(); } |