You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: aspnetcore/blazor/performance/webassembly-event-pipe-diagnostics.md
+22-8Lines changed: 22 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -41,11 +41,25 @@ The MSBuild properties in the following table enable profiler integration.
41
41
42
42
Property | Default | Set value to… | Description
43
43
--- | :---: | :---: | ---
44
-
`<WasmPerfTracing>` | `false` | `true` | Controls diagnostic server tracing.
45
-
`<MetricsSupport>` | `false` | `true` | Controls `System.Diagnostics.Metrics` support. For more information, see the [`System.Diagnostics.Metrics` namespace](/dotnet/api/system.diagnostics.metrics).
46
-
`<EventSourceSupport>` | `false`| `true` | Controls `EventPipe` support. For more information, see [Diagnostics and instrumentation: Observability and telemetry](/dotnet/core/deploying/native-aot/diagnostics#observability-and-telemetry).
47
-
48
-
Enabling profilers has negative size and performance impact, so don't publish an app for production with profilers enabled. In the following example, a condition is set on a property group section that only enables profiling when the app is built with `/p:BlazorSampleProfilingEnabled=true` (.NET CLI) or `<BlazorSampleProfilingEnabled>true</BlazorSampleProfilingEnabled>` in a Visual Studio publish profile, where "`BlazorSampleProfilingEnabled`" is a custom symbol name that you choose and doesn't conflict with other symbol names.
44
+
`<WasmPerfTracing>` | `false` | `true` | Enables support for WebAssembly performance tracing.
45
+
`<WasmPerfInstrumentation>` | No value | See table† | Enables instrumentation necessary for the sampling profiler. The property follows the :::no-loc text="callspec"::: syntax. †For permissible values, see the following table.
46
+
`<MetricsSupport>` | `false` | `true` | Enables `System.Diagnostics.Metrics` support. For more information, see the [`System.Diagnostics.Metrics` namespace](/dotnet/api/system.diagnostics.metrics).
47
+
`<EventSourceSupport>` | `false`| `true` | Enables `EventPipe` support. For more information, see [Diagnostics and instrumentation: Observability and telemetry](/dotnet/core/deploying/native-aot/diagnostics#observability-and-telemetry).
48
+
49
+
The following table describes permissable `<WasmPerfInstrumentation>` values.
50
+
51
+
`<WasmPerfInstrumentation>` value | Description
52
+
--- | ---
53
+
`all` | All assemblies
54
+
`program` | Entry point assembly
55
+
`{ASSEMBLY}` | Specifies an assembly (`{ASSEMBLY}`)
56
+
`M:Type:{METHOD}` | Specifies a method (`{METHOD}`)
57
+
`N:{NAMESPACE}` | Specifies a namespace (`{NAMESPACE}`)
58
+
`T:{TYPE}` | Specifies a type (`{TYPE}`)
59
+
`+EXPR` | Includes expression
60
+
`-EXPR` | Excludes expression
61
+
62
+
Enabling profilers has negative size and performance impacts, so don't publish an app for production with profilers enabled. In the following example, a condition is set on a property group section that only enables profiling when the app is built with `/p:BlazorSampleProfilingEnabled=true` (.NET CLI) or `<BlazorSampleProfilingEnabled>true</BlazorSampleProfilingEnabled>` in a Visual Studio publish profile, where "`BlazorSampleProfilingEnabled`" is a custom symbol name that you choose and doesn't conflict with other symbol names.
49
63
50
64
In the app's project file (`.csproj`):
51
65
@@ -60,7 +74,7 @@ In the app's project file (`.csproj`):
60
74
Alternatively, enable features when the app is built with the .NET CLI. The following options passed to the `dotnet build` command mirror the preceding MS Build property configuration:
The [`Timing-Allow-Origin` HTTP header](https://developer.mozilla.org/docs/Web/HTTP/Reference/Headers/Timing-Allow-Origin) allows for more precise time measurements.
@@ -69,13 +83,13 @@ The [`Timing-Allow-Origin` HTTP header](https://developer.mozilla.org/docs/Web/H
69
83
70
84
[EventPipe](/dotnet/core/diagnostics/eventpipe) is a runtime component used to collect tracing data, similar to [ETW](/windows/win32/etw/event-tracing-portal) and [perf_events](https://wikipedia.org/wiki/Perf_%28Linux%29).
71
85
72
-
Use the `<WasmPerfInstrumentation>` property to enable CPU sampling instrumentation for diagnostic server. This setting isn't necessary for memory dump or counters. **Makes the app execute slower. Only set this to `true` for performance profiling.**
86
+
Use the `<WasmPerfInstrumentation>` property to enable CPU sampling instrumentation for diagnostic server. This setting isn't necessary for memory dump or counters. **Makes the app execute slower. Only enable this for performance profiling.**
73
87
74
88
Enabling profilers has negative size and performance impact, so don't publish an app for production with profilers enabled. In the following example, a condition is set on a property group section that only enables profiling when the app is built with `/p:BlazorSampleProfilingEnabled=true` (.NET CLI) or `<BlazorSampleProfilingEnabled>true</BlazorSampleProfilingEnabled>` in a Visual Studio publish profile, where "`BlazorSampleProfilingEnabled`" is a custom symbol name that you choose and doesn't conflict with other symbol names.
0 commit comments