This article applies to Visual Studio 2015. If you're looking for the latest Visual Studio documentation, use the version selector at the top left. We recommend upgrading to Visual Studio 2019. Download it here
The QueryCounters option lists the CPU (hardware) performance counters that are available on the computer.
QueryCounters must be the only option on the command line.
When you are using the instrumentation method, the profiler can collect the values of one or more CPU performance counters at each data collection event. When you are using the sampling profiling method, you can specify one counter event and the number of event occurrences to be used as the sampling interval.
Different processors expose different CPU performance counters. The profiler defines a set of generic counters that can be used on almost all processors. The QueryCounters option lists both the names of the generic counters and the names of the counters that are specific to the processor.