diff options
author | Jan Kotas <jkotas@microsoft.com> | 2019-01-04 14:55:56 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-01-04 14:55:56 -0800 |
commit | 2301baeda250ecbc557430dca7ea70afdc968d52 (patch) | |
tree | 78f2ddae88d28d61d3e951ae464bb948224ff8bb /src | |
parent | 2ee2cb3a35fe1fa8d2d3b54c6839368ab8c89b73 (diff) | |
download | coreclr-2301baeda250ecbc557430dca7ea70afdc968d52.tar.gz coreclr-2301baeda250ecbc557430dca7ea70afdc968d52.tar.bz2 coreclr-2301baeda250ecbc557430dca7ea70afdc968d52.zip |
Delete unused fFullReset argument (#21814)
Diffstat (limited to 'src')
-rw-r--r-- | src/vm/comthreadpool.cpp | 2 | ||||
-rw-r--r-- | src/vm/finalizerthread.cpp | 4 | ||||
-rw-r--r-- | src/vm/nativeoverlapped.cpp | 2 | ||||
-rw-r--r-- | src/vm/threadpoolrequest.cpp | 2 | ||||
-rw-r--r-- | src/vm/threads.cpp | 32 | ||||
-rw-r--r-- | src/vm/threads.h | 5 | ||||
-rw-r--r-- | src/vm/win32threadpool.cpp | 6 |
7 files changed, 10 insertions, 43 deletions
diff --git a/src/vm/comthreadpool.cpp b/src/vm/comthreadpool.cpp index c7492a4c2d..11319e1c2d 100644 --- a/src/vm/comthreadpool.cpp +++ b/src/vm/comthreadpool.cpp @@ -262,7 +262,7 @@ FCIMPL0(FC_BOOL_RET, ThreadPoolNative::NotifyRequestComplete) } if (needReset) - pThread->InternalReset(FALSE, TRUE, TRUE, FALSE); + pThread->InternalReset(TRUE, TRUE, FALSE); HELPER_METHOD_FRAME_END(); } diff --git a/src/vm/finalizerthread.cpp b/src/vm/finalizerthread.cpp index a9d94c599c..f432571334 100644 --- a/src/vm/finalizerthread.cpp +++ b/src/vm/finalizerthread.cpp @@ -175,7 +175,7 @@ Object * FinalizerThread::DoOneFinalization(Object* fobj, Thread* pThread,int bi CallFinalizer(fobj); } } - pThread->InternalReset(FALSE); + pThread->InternalReset(); } else { @@ -202,7 +202,7 @@ Object * FinalizerThread::DoOneFinalization(Object* fobj, Thread* pThread,int bi &args, pThreadTurnAround); } - pThread->InternalReset(FALSE); + pThread->InternalReset(); // process the object we got back or be done if we got back null pReturnObject = OBJECTREFToObject(args.fobj); GCPROTECT_END(); diff --git a/src/vm/nativeoverlapped.cpp b/src/vm/nativeoverlapped.cpp index da4b572b2b..9bb1190c77 100644 --- a/src/vm/nativeoverlapped.cpp +++ b/src/vm/nativeoverlapped.cpp @@ -61,7 +61,7 @@ FCIMPL3(void, CheckVMForIOPacket, LPOVERLAPPED* lpOverlapped, DWORD* errorCode, if(!pThread->IsRealThreadPoolResetNeeded()) { pThread->ResetManagedThreadObjectInCoopMode(ThreadNative::PRIORITY_NORMAL); - pThread->InternalReset(FALSE, TRUE, FALSE, FALSE); + pThread->InternalReset(TRUE, FALSE, FALSE); if(ThreadpoolMgr::ShouldGrowCompletionPortThreadpool(ThreadpoolMgr::CPThreadCounter.DangerousGetDirtyCounts())) { //We may have to create a CP thread, go back to the Vm, and process the packet there. diff --git a/src/vm/threadpoolrequest.cpp b/src/vm/threadpoolrequest.cpp index 66fe1f48ff..7bfb413735 100644 --- a/src/vm/threadpoolrequest.cpp +++ b/src/vm/threadpoolrequest.cpp @@ -563,7 +563,7 @@ void UnManagedPerAppDomainTPCount::DispatchWorkItem(bool* foundWork, bool* wasNo { pThread->EEResetAbort(Thread::TAR_ALL); } - pThread->InternalReset(FALSE); + pThread->InternalReset(); } endTime = GetTickCount(); diff --git a/src/vm/threads.cpp b/src/vm/threads.cpp index fa316762c1..1ba012a8ab 100644 --- a/src/vm/threads.cpp +++ b/src/vm/threads.cpp @@ -8771,30 +8771,6 @@ INT32 Thread::ResetManagedThreadObjectInCoopMode(INT32 nPriority) return nPriority; } -void Thread::FullResetThread() -{ - CONTRACTL { - NOTHROW; - GC_TRIGGERS; - } - CONTRACTL_END; - - GCX_COOP(); - - // We need to put this thread in COOPERATIVE GC first to solve race between AppDomain::Unload - // and Thread::Reset. AppDomain::Unload does a full GC to collect all roots in one AppDomain. - // ThreadStaticData used to be coupled with a managed array of objects in the managed Thread - // object, however this is no longer the case. - - // TODO: Do we still need to put this thread into COOP mode? - - GCX_FORBID(); - DeleteThreadStaticData(); - - m_alloc_context.alloc_bytes = 0; - m_fPromoted = FALSE; -} - BOOL Thread::IsRealThreadPoolResetNeeded() { CONTRACTL @@ -8822,7 +8798,7 @@ BOOL Thread::IsRealThreadPoolResetNeeded() return FALSE; } -void Thread::InternalReset(BOOL fFull, BOOL fNotFinalizerThread, BOOL fThreadObjectResetNeeded, BOOL fResetAbort) +void Thread::InternalReset(BOOL fNotFinalizerThread, BOOL fThreadObjectResetNeeded, BOOL fResetAbort) { CONTRACTL { NOTHROW; @@ -8846,12 +8822,6 @@ void Thread::InternalReset(BOOL fFull, BOOL fNotFinalizerThread, BOOL fThreadObj nPriority = ResetManagedThreadObject(nPriority); } - if (fFull) - { - FullResetThread(); - } - - //m_MarshalAlloc.Collapse(NULL); if (fResetAbort && IsAbortRequested()) { diff --git a/src/vm/threads.h b/src/vm/threads.h index dbbb00b0bf..e6e7cbf176 100644 --- a/src/vm/threads.h +++ b/src/vm/threads.h @@ -1317,13 +1317,10 @@ public: STDMETHODIMP EndPreventAsyncAbort() DAC_EMPTY_RET(E_FAIL); - void InternalReset (BOOL fFull, BOOL fNotFinalizerThread=FALSE, BOOL fThreadObjectResetNeeded=TRUE, BOOL fResetAbort=TRUE); + void InternalReset (BOOL fNotFinalizerThread=FALSE, BOOL fThreadObjectResetNeeded=TRUE, BOOL fResetAbort=TRUE); INT32 ResetManagedThreadObject(INT32 nPriority); INT32 ResetManagedThreadObjectInCoopMode(INT32 nPriority); BOOL IsRealThreadPoolResetNeeded(); -private: - //Helpers for reset... - void FullResetThread(); public: HRESULT DetachThread(BOOL fDLLThreadDetach); diff --git a/src/vm/win32threadpool.cpp b/src/vm/win32threadpool.cpp index 644e2324c6..330dcffe8d 100644 --- a/src/vm/win32threadpool.cpp +++ b/src/vm/win32threadpool.cpp @@ -722,7 +722,7 @@ void QueueUserWorkItemHelp(LPTHREAD_START_ROUTINE Function, PVOID Context) if (pThread) { if (pThread->IsAbortRequested()) pThread->EEResetAbort(Thread::TAR_ALL); - pThread->InternalReset(FALSE); + pThread->InternalReset(); } } @@ -2036,7 +2036,7 @@ Work: { if (pThread->IsAbortRequested()) pThread->EEResetAbort(Thread::TAR_ALL); - pThread->InternalReset(FALSE); + pThread->InternalReset(); } } @@ -3657,7 +3657,7 @@ Top: if (pThread) { if (pThread->IsAbortRequested()) pThread->EEResetAbort(Thread::TAR_ALL); - pThread->InternalReset(FALSE); + pThread->InternalReset(); } } else |