Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All


The TargetCLR option specifies the version of the common language run-time (CLR) to profile when more than one version of the CLR is loaded in an application.

By default, the Visual Studio Profiling Tools target the first version of the CLR that is loaded by the application. 

VSPerfCmd.exe {/Launch:AppName | /Attach:PID} /TargetCLR[:ClrVersion] [Options] 


The version number of the CLR. Use the version format vN.N.NNNNN.

The TargetCLR option can only be used with the Launch or Attach options.

Launch: AppName

Starts the specified application and starts to profile.

Attach: PID

Starts to profile the specified process.

In this example, the TargetCLR option is used to make sure that CLR version 4.0.11003 is profiled.

VSPerfCmd.exe /Start:Sample /Output:TestApp.exe.vsp
VSPerfCmd.exe /Launch:TestApp.exe /TargetCLR:v4.0.11003
© 2015 Microsoft