diff options
Diffstat (limited to 'src/vm/ceemain.cpp')
-rw-r--r-- | src/vm/ceemain.cpp | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/src/vm/ceemain.cpp b/src/vm/ceemain.cpp index 9cce46d2f0..c03c40134b 100644 --- a/src/vm/ceemain.cpp +++ b/src/vm/ceemain.cpp @@ -693,6 +693,11 @@ void EEStartupHelper(COINITIEE fFlags) InitThreadManager(); STRESS_LOG0(LF_STARTUP, LL_ALWAYS, "Returned successfully from InitThreadManager"); +#ifdef FEATURE_PERFTRACING + // Initialize the event pipe. + EventPipe::Initialize(); +#endif // FEATURE_PERFTRACING + #ifdef FEATURE_EVENT_TRACE // Initialize event tracing early so we can trace CLR startup time events. InitializeEventTracing(); @@ -1036,8 +1041,7 @@ void EEStartupHelper(COINITIEE fFlags) #endif #ifdef FEATURE_PERFTRACING - // Initialize the event pipe and start it if requested. - EventPipe::Initialize(); + // Start the event pipe if requested. EventPipe::EnableOnStartup(); #endif // FEATURE_PERFTRACING @@ -1576,6 +1580,11 @@ void STDMETHODCALLTYPE EEShutDownHelper(BOOL fIsDllUnloading) ETW::EnumerationLog::ProcessShutdown(); } +#ifdef FEATURE_PERFTRACING + // Shutdown the event pipe. + EventPipe::Shutdown(); +#endif // FEATURE_PERFTRACING + #if defined(FEATURE_COMINTEROP) // Get the current thread. Thread * pThisThread = GetThread(); @@ -1708,11 +1717,6 @@ void STDMETHODCALLTYPE EEShutDownHelper(BOOL fIsDllUnloading) PerfMap::Destroy(); #endif -#ifdef FEATURE_PERFTRACING - // Shutdown the event pipe. - EventPipe::Shutdown(); -#endif // FEATURE_PERFTRACING - #ifdef FEATURE_PREJIT { // If we're doing basic block profiling, we need to write the log files to disk. |