Skip to content
This repository was archived by the owner on Jan 23, 2023. It is now read-only.

Commit 8f5f8dc

Browse files
committed
Change FinalizerThreadCreate location to after profiler is initialized (#13663)
* Change FinalizerThreadCreate location to after profiler is initialized to ensure finalizer creation notification to profilerAPI * Fixes issue #13499
1 parent 1b28a11 commit 8f5f8dc

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/vm/ceemain.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -912,10 +912,6 @@ void EEStartupHelper(COINITIEE fFlags)
912912

913913
#ifndef CROSSGEN_COMPILE
914914

915-
// This isn't done as part of InitializeGarbageCollector() above because thread
916-
// creation requires AppDomains to have been set up.
917-
FinalizerThread::FinalizerThreadCreate();
918-
919915
#ifndef FEATURE_PAL
920916
// Watson initialization must precede InitializeDebugger() and InstallUnhandledExceptionFilter()
921917
// because on CoreCLR when Waston is enabled, debugging service needs to be enabled and UEF will be used.
@@ -1025,6 +1021,10 @@ void EEStartupHelper(COINITIEE fFlags)
10251021
hr = g_pGCHeap->Initialize();
10261022
IfFailGo(hr);
10271023

1024+
// This isn't done as part of InitializeGarbageCollector() above because thread
1025+
// creation requires AppDomains to have been set up.
1026+
FinalizerThread::FinalizerThreadCreate();
1027+
10281028
// Now we really have fully initialized the garbage collector
10291029
SetGarbageCollectorFullyInitialized();
10301030

0 commit comments

Comments
 (0)