projects
/
platform
/
upstream
/
coreclr.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2e92b4a
)
Don't create the sampling thread if the threadtime event is disabled. (#15473)
author
Brian Robbins
<brianrob@microsoft.com>
Tue, 12 Dec 2017 22:19:19 +0000
(14:19 -0800)
committer
GitHub
<noreply@github.com>
Tue, 12 Dec 2017 22:19:19 +0000
(14:19 -0800)
src/vm/sampleprofiler.cpp
patch
|
blob
|
history
diff --git
a/src/vm/sampleprofiler.cpp
b/src/vm/sampleprofiler.cpp
index
4a858e9
..
d99667e
100644
(file)
--- a/
src/vm/sampleprofiler.cpp
+++ b/
src/vm/sampleprofiler.cpp
@@
-45,6
+45,12
@@
void SampleProfiler::Enable()
false /* NeedStack */);
}
+ // Check to see if the sample profiler event is enabled. If it is not, do not spin up the sampling thread.
+ if(!s_pThreadTimeEvent->IsEnabled())
+ {
+ return;
+ }
+
if(s_pPayloadExternal == NULL)
{
s_pPayloadExternal = new BYTE[sizeof(unsigned int)];