Performance tracing with HoloLens
Performance tracing with HoloLens is a powerful way to find and resolve computational or hardware bottlenecks. When traces are analyzed with the Windows Performance Analyzer, you're able to visualize and explore hardware or software bottlenecks. Examples of this might be something that's causing a HoloLens to overheat or CPU processes that are especially taxing on the system.
Use WPA to analyze performance traces
Performance Trace Analysis in WPA
To get a detailed understanding of system and application behavior and resource usage for HoloLens, you can use the performance tracing feature. This feature captures Windows Performance Recorder traces in the form of an event trace log (ETL) file for use in the Windows Performance Analyzer (WPA).
Installation
To analyze a trace file, download WPA from the Microsoft Store.
For more general purpose debugging tools, you can also use the Windows Performance Toolkit. To get this toolkit, download the Windows Assessment and Deployment Kit.
Terminology
When searching for information about performance traces, you'll inevitably come across a range of terms. The most important ones are:
Term | Definition |
---|---|
ETW | Event Tracing for Windows: The overarching name for kernel-level tracing facility that's built into Windows. |
ETL | Event Trace Log: The file extension for files that store the tracing data. Thus, when you do a trace, you typically will have an *.etl file afterwards. |
WPR | Windows Performance Recorder: The application that starts and stops the recording of event traces. WPR takes a profile file (*.wprp) that configures which exact events to log. Below, you’ll learn how to do a trace for HoloLens through the Windows Device Portal. |
WPA | Windows Performance Analyzer: A GUI application that's used to open *.etl files and sift through data to identify performance issues. WPA allows you to sort data by various criteria, display the data in several ways, dig down into details, and correlate information. |
Recording a trace on HoloLens
Generate an ETL file using the Device Portal in your HoloLens.
Performance tracing page in Device Portal for HoloLens 2
Perform a trace
- On the left, navigate to Performance > Performance Tracing.
- Choose an available profile or select Custom profiles > Browse then do one of the following:
- Use your own custom profile
- Use this example profile to analyze CPU performance
- Create your own custom profile
- Click Start Trace.
- The HoloLens is now recording a trace. Make sure to trigger the performance issues that you want to investigate, and then select Stop Trace.
- The trace will be listed at the bottom of the webpage. Select the disk icon at the right-hand side to download the ETL file.
You now have an ETL file that you can either open directly in WPA or send to someone else.
Analyzing traces with WPA
Windows Performance Analyzer is the standard tool to visualize traces as graphs and tables to allow you to analyze system and application performance. WPA is a powerful, multifaceted tool, so we won't explain it in detail here. For more detail, use the Step-by-step guide to use Windows Performance Analyzer.
To learn more about WPA, have a look at these resources:
- Watch the introductory videos for a first overview.
- WPA itself has a Getting Started tab, which explains common steps.
- Learn about the WPA User Interface.
- There's excellent information on this website--however, not all of it's relevant for beginners.
Files you need for WPA trace analysis
There are several files you'll need to analyze your trace file in WPA. We've included an example WPA profile to help you get started.
- HoloLens trace file
(*.etl)
- Symbol file
(*.pdb)
. Make sure it's extracted (not zipped). - WPA profile
(*.wpaProfile)
. Use this example WPA Profile for CPU analysis.
Perform analysis of trace file
Set up your files in a folder for WPA to access them.
Example
Folder_for_WPA_files ├─ HoloLens_trace_file.elt - # HoloLens trace file (*.etl) ├─ CPU_analysis.wpaProfile - # WPA Profile (*.wpaProfile) └─ Symbols - # Make sure it's extracted (not zipped). ├─ *.pdb ├─ *.pdb └─ ...
Launch the Windows Performance Analyzer (WPA).
Open the ETL trace file by selecting File > Open > select the
.etl
in your file browser.Load symbol file into WPA by selecting Trace > Load Symbols.
Tip
Configure extra symbol paths by selecting Trace > Configure Symbol Paths.
Apply WPA profile to generate graphs for analysis. In your WPA folder, select Profiles > Apply > Browse > choose the
*.wpaProfile
file > Apply.Once graphs are selected, WPA will display them in the Analysis tab.
Dive Deeper
To learn more about WPA, see the WPA documentation.
Next steps
Dive deeper into WPA or learn more about performance tracing.