Bagikan melalui


Profiling Windows 8 and Windows Server 2012 applications

Enhanced security features in Windows 8 and Windows Server 2012 required significant changes in the way the Visual Studio profiler collects data on these platforms. Windows Store apps also require new collection techniques. This topic describes the changes for profiling on Windows 8 and Windows Server 2012 platforms.

Note

Profiling applications on other supported versions of Windows (Windows 7, Windows Server 2008 R2) has not changed.

In this topic

Profiling Windows Store apps from the Visual Studio IDE

Profiling apps running on the Windows 8 desktop or on Windows Server 2012 from the Visual Studio IDE

  • Profiling apps running on the Windows 8 desktop or on Windows Server 2012 by using sampling from the Visual Studio IDE

Profiling from the command line

Collecting tier interaction (TIP) data

Profiling Windows Store apps from the Visual Studio IDE

When you profile a Windows Store app that is written in JavaScript and HTML 5, you collect instrumentation data for the JavaScript code. When you profile a Windows Store app or component that is written in Visual C++, Visual C#, or Visual Basic, you collect sampling data for the native and managed code. You can profile your app locally or on a remote machine.

These profiling features and options are not supported when profiling Windows Store apps:

  • Profiling JavaScript apps using the sampling method.

  • Profiling managed and native code using the instrumentation method.

  • Concurrency profiling

  • .NET memory profiling

  • Tier interaction profiling (TIP)

  • Sampling options, such as setting the sampling event and timing interval, or collecting additional performance counter data.

  • Instrumentation options, such as collecting performance and windows counter data, or specifying additional command-line options.

For more information about profiling Windows Store apps, see the following topics in the Windows Dev Center:

Running Windows Store apps on the local machine

Running Windows Store apps on a remote machine

Analyzing the performance of Windows Store apps

In this topic

Profiling apps running on the Windows 8 desktop or on Windows Server 2012 from the Visual Studio IDE

Profiling using the instrumentation method has not changed for Windows 8.

Tier interaction profiling (TIP) is not supported using the sampling method.

Profiling apps running on the Windows 8 desktop or on Windows Server 2012 by using sampling from the Visual Studio IDE

These profiling features and options are not supported when profiling Windows 8 desktop applications or Windows Server 2012 applications using the sampling method:

  • Tier interaction profiling (TIP). Collecting TIP data is supported using instrumentation.

  • Sampling options such as setting the sampling event and timing interval, or collecting additional performance counter data.

Profiling from the command line

You use two command line tools to collect profiling data on Windows 8 and Windows Server 2012 devices, including devices that do not have an installation of Visual Studio:

Tool name

Description

VSPerf

Collects profiling data from Windows Store apps and collects sample profiling data from Windows 8 desktop applications and Windows Server 2012 applications..

VSPerfCmd

Collects instrumentation, concurrency, and tier interaction profiling data from apps that are running on theWindows 8 desktop or Windows Server 2012. Collects all types of profiling data from previous versions of Windows.

Both tools are installed with Visual Studio for use on the local computer.

To profile applications on devices that do not have Visual Studio installed, do one of the following:

  • Download the tools as part of the Remote Tools for Visual Studio from the MSDN web site.

  • Copy and run the stand-alone profiler tools installation program from your Visual Studio computer. The installation programs are in %VSInstallDir% \Team Tools\Performance Tools\Setups folder. Choose the setup program for the operating system (x86/x64) of the remote computer.

Note

To collect TIP profiling data, you must install the stand-alone profiler from your Visual Studio machine on the remote computer.

These profiling features and options are not supported when profiling Windows 8 and Windows Server 2012 applications from the command line:

  • Collecting data from Windows 8 and Windows Server 2012 web apps by using sampling mode with VSPerfASPNetCmd.

  • Collecting sampling data by using VsPerfCmd.exe.

  • Sampling options such as setting the sampling event and timing interval, or collecting additional performance counter data.

Collecting tier interaction (TIP) data

Tier interaction profiling provides additional information about the execution times of functions of multi-tiered applications that communicate with databases through ADO.NET services. Data is collected only for synchronous function calls.

Visual Studio editions

Tier interaction profiling data can be collected using Visual Studio Ultimate, Visual Studio Premium, or Visual Studio Professional. However, tier interaction profiling data can be viewed only in Visual Studio Ultimate and Visual Studio Premium.

Windows 8 and Windows Server 2012

  1. To collect tier interaction data from apps that are running on the Windows 8 desktop or Windows Server 2012, you must use the instrumentation method.

  2. You cannot collect tier interaction data for Windows Store apps.

  3. You can include tier interaction data in all profiling methods on other supported version of Windows.

Performance Wizard and Performance Explorer

You must add the tier interaction data collection option to a profiling run from the Performance Explorer. You must also add the project, executable, or website to the Target node of Performance Explorer. See Collecting tier interaction data by using the Visual Studio IDE.

Collecting TIP data on a remote machine

To collect tier interaction data on a remote machine, you must copy the vs_profiler_<Platform>_<Language>.exe file from the %VSInstallDir%\Team Tools\Performance Tools\Setups folder of a Visual Studio machine to the remote computer and install it. You cannot use the profiling tools in the Visual Studio Remote Tools download package.

You can use VSPerfCmd or VSPerfASPNetCmd to collect the profiling data.

TIP reports

Tier interaction data can only be viewed in the Visual Studio Ultimate, Visual Studio Premium, or Visual Studio Professional IDE. File based tier interaction reports through VSPerfReport are not available.

See Also

Concepts

Analyzing Application Performance by Using Profiling Tools

Configuring Performance Sessions for Profiling Tools

Using the Profiling Tools From the Command-Line