summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorSung Yoon Whang <suwhang@microsoft.com>2019-07-01 23:19:07 -0700
committerGitHub <noreply@github.com>2019-07-01 23:19:07 -0700
commitf9a6e873747dbefeca9016e31378d532ce56f293 (patch)
tree6ec0582906a4f333759a4f58b74e919549397c3e /src
parent0d8304713fb2766b84c90616d2b88a622db1924e (diff)
downloadcoreclr-f9a6e873747dbefeca9016e31378d532ce56f293.tar.gz
coreclr-f9a6e873747dbefeca9016e31378d532ce56f293.tar.bz2
coreclr-f9a6e873747dbefeca9016e31378d532ce56f293.zip
Decrease EventListener buffer size (#25526)
* Reduce the default EventPipe circularBufferSize to 10MB for EventListener sessions * make it a static var instead of random # in the code
Diffstat (limited to 'src')
-rw-r--r--src/System.Private.CoreLib/src/System/Diagnostics/Eventing/EventPipeEventDispatcher.cs4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/System.Private.CoreLib/src/System/Diagnostics/Eventing/EventPipeEventDispatcher.cs b/src/System.Private.CoreLib/src/System/Diagnostics/Eventing/EventPipeEventDispatcher.cs
index a58d4eb750..4360283247 100644
--- a/src/System.Private.CoreLib/src/System/Diagnostics/Eventing/EventPipeEventDispatcher.cs
+++ b/src/System.Private.CoreLib/src/System/Diagnostics/Eventing/EventPipeEventDispatcher.cs
@@ -36,6 +36,8 @@ namespace System.Diagnostics.Tracing
private object m_dispatchControlLock = new object();
private Dictionary<EventListener, EventListenerSubscription> m_subscriptions = new Dictionary<EventListener, EventListenerSubscription>();
+ private static uint DefaultEventListenerCircularMBSize = 10;
+
private EventPipeEventDispatcher()
{
// Get the ID of the runtime provider so that it can be used as a filter when processing events.
@@ -110,7 +112,7 @@ namespace System.Diagnostics.Tracing
new EventPipeProviderConfiguration(NativeRuntimeEventSource.EventSourceName, (ulong) aggregatedKeywords, (uint) highestLevel, null)
};
- m_sessionID = EventPipeInternal.Enable(null, EventPipeSerializationFormat.NetTrace, 1024, providerConfiguration, 1);
+ m_sessionID = EventPipeInternal.Enable(null, EventPipeSerializationFormat.NetTrace, DefaultEventListenerCircularMBSize, providerConfiguration, 1);
Debug.Assert(m_sessionID != 0);
// Get the session information that is required to properly dispatch events.