PerfView is a set of integrated profiling and tracing tools built on Windows Event Tracing for Windows (ETW), designed to diagnose CPU, memory, and ETW-based performance issues in .NET applications. It captures ETW events to analyze runtime behavior, CPU usage, and memory allocations, serving as a .NET performance profiler that measures both CPU time and garbage collection events.
The tool distinguishes itself with a diff comparison engine that compares two performance traces side-by-side to highlight changes in method costs and event rates. It renders profiled call stacks as flame graphs where wider bars indicate higher execution time, and provides heap snapshot analysis to identify memory leaks and allocation patterns. PerfView can attach to running processes to collect trace data and detach without terminating the target, and it resolves raw addresses in stack traces to function names and source lines using debug symbols.
Additional capabilities include CPU sampling profiling that attributes CPU time to code paths, object allocation tracing to reduce memory pressure, and detailed analysis of garbage collection patterns. The underlying trace event processing engine parses and transforms raw ETW event streams into structured performance data for analysis of both Windows kernel and user-mode events.