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: docs/profiling/choose-performance-tool.md
+5-2Lines changed: 5 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -33,11 +33,12 @@ The following table lists the different tools Visual Studio offers and provides
33
33
|[Memory Usage](../profiling/memory-usage.md)|Shows your app’s memory to find issues such as memory leaks.|• Optimize memory usage</br>• Investigate UI freeze</br>• Investigate suspected memory leak (native code)|
34
34
|[.NET Object Allocation](../profiling/dotnet-alloc-tool.md)|Shows where .NET Objects are allocated and information about garbage collection.|• Optimize .NET memory usage</br>• Analyze garbage collection|
35
35
|[Instrumentation](../profiling/instrumentation-overview.md)|Shows exact call counts and call times.|• You need a tool like CPU Usage, but you want exact call counts and time spent in functions based on wall clock time.</br>• You want to see blocked time, such as time spent waiting for locks.</br>• Note: This tool requires extra overhead.|
36
+
|[.NET Counters](../profiling/dotnet-counters-tool.md)|Live report for .NET counters.|• Begin an investigation for general performance issues.</br>• You want a trace for .NET counter-based metrics such as exceptions per second, garbage collection, and CPU utilization.|
37
+
|[BenchmarkDotNet](../profiling/profiling-with-benchmark-dotnet.md)|Report for benchmarks based on BenchmarkDotNet.|• Compare performance against baseline runs. Helps you to understand the impact of code changes on performance.|
36
38
|[File I/O](../profiling/use-file-io.md)|Shows your File I/O operations and how long they take and how much data they process.|Investigate UI freeze|
37
39
|[PerfTips](../profiling/perftips.md)|Shows a quick measurement of performance information while interacting with your code.|While debugging, you want to see the elapsed time between the previous step operation (or breakpoint) to the current step or breakpoint.|
38
40
|[Events viewer](../profiling/events-viewer.md)|Shows HTTP requests, log messages, and exceptions.|• Investigate latency in API calls</br>• Investigate slow application running on a remote web server|
39
41
|[.NET Async](../profiling/analyze-async.md)|Shows async/await usage in .NET apps.|Investigate suspected performance issue with asynchronous code.|
40
-
|[.NET Counters](../profiling/dotnet-counters-tool.md)|Live report for .NET counters.|• Begin an investigation for general performance issues.</br>• You want a trace for .NET counter-based metrics such as exceptions per second, garbage collection, and CPU utilization.|
41
42
|[Database](../profiling/analyze-database.md)|Shows performance of your database queries.|Investigate performance for database queries that use either ADO.NET or Entity Framework Core.|
42
43
|[GPU Usage](./gpu-usage.md)|Shows high-level hardware usage of your Direct3D app.|Check whether the performance of your app is CPU-bound or GPU-bound.|
43
44
|[Application Timeline](../profiling/application-timeline.md)|Shows UI performance for XAML apps.|Investigate UI performance in XAML apps, such as time spent rendering frames.|
@@ -53,11 +54,12 @@ The following table lists the different tools Visual Studio offers and the diffe
This tool is supported for For .NET Core and .NET 5+ apps.
277
+
278
+
## Visualize BenchmarkDotNet data
279
+
280
+
Starting in Visual Studio 2022 version 17.9, you can view data collected using BenchmarkDotNet in the Visual Studio profiling tools. By adding benchmark attributes to your code, you can measure performance against a baseline run. For more information, see [Analyze BenchmarkDotNet data in Visual Studio](../profiling/profiling-with-benchmark-dotnet.md).
281
+
282
+
:::image type="content" source="../profiling/media/vs-2022/benchmark-dotnet-diagsession.png" alt-text="BenchmarkDotNet data in the profiler.":::
Copy file name to clipboardExpand all lines: docs/profiling/profiling-with-benchmark-dotnet.md
+10Lines changed: 10 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -115,8 +115,18 @@ Each diagnoser generates performance data related to that diagnoser. For example
115
115
116
116

117
117
118
+
1. Right-click a row in the results and choose **Select time range** to sync the timeline with the benchmark
119
+
118
120
For more information about the results, see [BenchmarkDotNet](https://benchmarkdotnet.org/articles/overview.html) documentation.
119
121
122
+
## Analyze additional data
123
+
124
+
Depending on the diagnoser you used, you can analyze the collected BenchmarkDotNet data to gain insights related to memory allocation, CPU usage, counters, and other data.
125
+
126
+
- In the profiler, open one of the tabs such as **CPU Usage** or **Allocations**.
127
+
128
+
For an example using the memory diagnoser, see the blog post [Benchmarking with Visual Studio Profiler](https://devblogs.microsoft.com/visualstudio/benchmarking-with-visual-studio-profiler/).
129
+
120
130
## Related content
121
131
122
132
-[First look at profiling](../profiling/choose-performance-tool.md)
0 commit comments