From 382dbe4ba82f57a138484e0c5052c3b8606c1294 Mon Sep 17 00:00:00 2001 From: Marek Safar Date: Tue, 5 Feb 2019 04:43:10 +0100 Subject: Move SynchronizationContext to shared partition (#22389) * Move SynchronizationContext to shared partition * Move WaitHelperNative to WaitHandle --- src/vm/synchronizationcontextnative.cpp | 29 ----------------------------- 1 file changed, 29 deletions(-) (limited to 'src/vm/synchronizationcontextnative.cpp') diff --git a/src/vm/synchronizationcontextnative.cpp b/src/vm/synchronizationcontextnative.cpp index 03b289fc95..654f69e3ab 100644 --- a/src/vm/synchronizationcontextnative.cpp +++ b/src/vm/synchronizationcontextnative.cpp @@ -18,37 +18,8 @@ #include #include #include "winrtdispatcherqueue.h" -#endif #include "synchronizationcontextnative.h" - -FCIMPL3(DWORD, SynchronizationContextNative::WaitHelper, PTRArray *handleArrayUNSAFE, CLR_BOOL waitAll, DWORD millis) -{ - FCALL_CONTRACT; - - DWORD ret = 0; - - PTRARRAYREF handleArrayObj = (PTRARRAYREF) handleArrayUNSAFE; - HELPER_METHOD_FRAME_BEGIN_RET_1(handleArrayObj); - - CQuickArray qbHandles; - int cHandles = handleArrayObj->GetNumComponents(); - - // Since DoAppropriateWait could cause a GC, we need to copy the handles to an unmanaged block - // of memory to ensure they aren't relocated during the call to DoAppropriateWait. - qbHandles.AllocThrows(cHandles); - memcpy(qbHandles.Ptr(), handleArrayObj->GetDataPtr(), cHandles * sizeof(HANDLE)); - - Thread * pThread = GetThread(); - ret = pThread->DoAppropriateWait(cHandles, qbHandles.Ptr(), waitAll, millis, - (WaitMode)(WaitMode_Alertable | WaitMode_IgnoreSyncCtx)); - - HELPER_METHOD_FRAME_END(); - return ret; -} -FCIMPLEND -#ifdef FEATURE_APPX - Volatile g_pICoreWindowStatic; void* QCALLTYPE SynchronizationContextNative::GetWinRTDispatcherForCurrentThread() -- cgit v1.2.3