Skip to content

Commit adbf826

Browse files
committed
Review of WPA plugin Learning Path
1 parent 8106708 commit adbf826

File tree

5 files changed

+121
-56
lines changed

5 files changed

+121
-56
lines changed

content/install-guides/windows-perf-wpa-plugin.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ layout: installtoolsall # DO NOT MODIFY. Always true for tool install articles
2929

3030
## What is the Windows Performance Analyzer plugin?
3131

32-
The Windows Performance Analyzer (WPA) plugin connects [Windows Perf](/learning-paths/laptops-and-desktops/windowsperf/) to the Windows Performance Analyzer. Windows Perf is a lightweight performance profiling tool inspired by Linux Perf and designed for Windows on Arm.
32+
The Windows Performance Analyzer (WPA) plugin connects [WindowsPerf](/learning-paths/laptops-and-desktops/windowsperf/) to the Windows Performance Analyzer. Windows Perf is a lightweight performance profiling tool inspired by Linux Perf and designed for Windows on Arm.
3333

3434
Windows Performance Analyzer is a useful tool that supports developers with diagnostics and performance tuning. It generates data tables and graphs of Event Tracing for Windows (ETW) events, which are recorded in one of three ways:
3535
- Windows Performance Recorder (WPR)

content/learning-paths/laptops-and-desktops/windowsperf_wpa_plugin/_index.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,20 @@
11
---
2-
title: Get started with WindowsPerf WPA Plugin
2+
title: Get started with the Windows Performance Analyzer (WPA) plugin for WindowsPerf
3+
4+
draft: true
5+
cascade:
6+
draft: true
37

48
minutes_to_complete: 15
59

6-
who_is_this_for: This is an introductory topic for software developers working on laptops and desktops and new to the Arm architecture.
10+
who_is_this_for: This is an introductory topic for software developers interested in using the Windows Performance Analyzer (WPA) plugin for performance analysis.
711

812
learning_objectives:
9-
- Install WindowsPerf WPA Plugin on Windows
10-
- Import a WindowsPerf counting timeline as a .json file in WPA
11-
- Visualize the timeline in WPA using the Windowsperf WPA Plugin
13+
- Import WindowsPerf data as a .json file in WPA.
14+
- Visualize the timeline and telemetry data in WPA using the WPA plugin.
1215

1316
prerequisites:
14-
- Windows desktop or development machine
15-
- Windows Performance Analyzer installed
16-
- WindowsPerf WPA Plugin installed
17-
- (Optional) [WindowsPerf](/install-guides/wperf/) installed on a WoA machine [(Installation guide)](/install-guides/wperf/)
17+
- A Windows on Arm laptop with WindowsPerf, Windows Performance Analyzer (WPA), and the WPA plugin installed.
1818

1919
author_primary: Alaaeddine Chakroun
2020

@@ -23,7 +23,7 @@ skilllevels: Introductory
2323
subjects: Performance and Architecture
2424
armips:
2525
- Cortex-A
26-
- neoverse
26+
- Neoverse
2727
operatingsystems:
2828
- Windows
2929
tools_software_languages:

content/learning-paths/laptops-and-desktops/windowsperf_wpa_plugin/_next-steps.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
next_step_guidance: Now that you have an idea of how the WindowsPerf WPA Plugin works, You can try exploring the WindowsPerf CLI for more flexibility.
2+
next_step_guidance: Now that you have an idea of how the WindowsPerf WPA plugin works, You can try exploring the WindowsPerf CLI for more flexibility.
33

44
recommended_path: "/learning-paths/laptops-and-desktops/windowsperf_sampling_cpython"
55

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
---
2+
# ================================================================================
3+
# Edit
4+
# ================================================================================
5+
6+
# Always 3 questions. Should try to test the reader's knowledge, and reinforce the key points you want them to remember.
7+
# question: A one sentence question
8+
# answers: The correct answers (from 2-4 answer options only). Should be surrounded by quotes.
9+
# correct_answer: An integer indicating what answer is correct (index starts from 0)
10+
# explanation: A short (1-3 sentence) explanation of why the correct answer is correct. Can add additional context if desired
11+
12+
13+
review:
14+
- questions:
15+
question: >
16+
The WPA plugin connects WindowsPerf to the Windows Performance Analyzer.
17+
answers:
18+
- "True"
19+
- "False"
20+
correct_answer: 1
21+
explanation: >
22+
The Windows Performance Analyzer (WPA) plugin connects WindowsPerf to the Windows Performance Analyzer.
23+
24+
- questions:
25+
question: >
26+
Which views can WPA display
27+
answers:
28+
- "Timeline"
29+
- "Telemetry"
30+
- "Function profile"
31+
- "Timeline and telemetry"
32+
- "All of the above"
33+
correct_answer: 3
34+
explanation: >
35+
WPA can display both the timeline and the telemetry views.
36+
37+
- questions:
38+
question: >
39+
WindowsPerf can output data in JSON format with `--json` command line option.
40+
answers:
41+
- "True"
42+
- "False"
43+
correct_answer: 1
44+
explanation: >
45+
Some `wperf` commands such as `list`, `test` or `stat` can output data in JSON format.
46+
47+
48+
# ================================================================================
49+
# FIXED, DO NOT MODIFY
50+
# ================================================================================
51+
title: "Review" # Always the same title
52+
weight: 20 # Set to always be larger than the content in this path
53+
layout: "learningpathall" # All files under learning paths have this same wrapper
54+
---
Lines changed: 55 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -1,93 +1,104 @@
11
---
22
layout: learningpathall
3-
title: WindowsPerf WPA Plugin
3+
title: Visualize data from WindowsPerf using WPA
44
weight: 2
55
---
66

7-
# Overview
7+
## Before you begin
88

9-
WindpwsPerf WPA plugin is a plugin built for WPA that parses JSON output of `wperf` command line tool to visualize counting and telemetry events as timeline graphs.
9+
The Windows Performance Analyzer (WPA) plugin connects WindowsPerf to the Windows Performance Analyzer.
1010

11-
[**WindowsPerf**](https://github.com/arm-developer-tools/windowsperf) is a lightweight performance profiling tool inspired by Linux perf, specifically tailored for Windows on Arm.
12-
It leverages the ARM64 PMU (Performance Monitor Unit) and its hardware counters to offer precise profiling capabilities.
13-
The [WindowsPerf WPA plugin](https://github.com/arm-developer-tools/windowsperf-wpa-plugin) bridges the gap between the detailed output of **WindowsPerf** and the powerful capabilities of [Windows Performance Analyzer](https://learn.microsoft.com/en-us/windows-hardware/test/wpt/windows-performance-analyzer).
11+
Before trying WPA with the WPA plugin, you need to install the following software on your Windows on Arm computer:
1412

15-
## WindowsPerf WPA Plugin releases
13+
- [WindowsPerf](/install-guides/wperf/)
14+
- [WPA plugin](/install-guides/windows-perf-wpa-plugin/)
1615

17-
You can find all binary releases of `WindowsPerf WPA Plugin` [here](https://github.com/arm-developer-tools/windowsperf-wpa-plugin/releases).
16+
The WPA plugin install guide includes the installation of WPA.
1817

19-
# Installation
18+
## Using WindowsPerf data in WPA
2019

21-
For installation instructions see the [install guide](/install-guides/windows-perf-wpa-plugin).
20+
In order to use WPA with WindowsPerf, you need to create a `.json` file which is created from a WindowsPerf `wperf stat` command running on a Windows on Arm machine.
2221

23-
## Using WindowsPerf WPA Plugin
22+
You can save a `.json` output from WindowsPerf by using the `--output` command followed by the filename.
2423

25-
In order to use the `WindowsPerf WPA Plugin`, we first need to get a `.json` output from a WindowsPerf `wperf stat` command running on a Windows on Arm machine.
26-
{{% notice Note%}}
27-
In order to get a `.json` output from WindowsPerf, we need to use the `--output` command followed by the filename.
28-
{{% /notice %}}
24+
1. Create a `.json` file
2925

30-
Example:
26+
To create a file named `example.json`, run the following command:
3127

32-
```command
33-
wperf stat -e ld_spec --output example.json
34-
```
28+
```console
29+
wperf stat -e ld_spec --output example.json
30+
```
31+
32+
2. Open Windows Performance Analyzer, and see the following window:
3533

36-
Upon opening Windows Performance Analyzer, we are greeted with the following window:
37-
![wpa-first-screen](figures/wpa-first-screen.png)
34+
![wpa-first-screen #center](figures/wpa-first-screen.png)
3835

39-
As we can see, the `WindowsPerf WPA Plugin` is installed correctly and it appears under the Installed Plugins section. We can then click on "Open file..." from the start menu on the left side and we're prompted to choose a `.json` file.
36+
Confirm the `WindowsPerf WPA Plugin` appears under the Installed Plugins section.
4037

41-
![wpa-open-file](figures/wpa-open-file.png)
38+
3. Open the `.json` file
4239

43-
By clicking "Open", the output file is then validated to check its format and compatibility with the plugin, and finally the main WPA window opens up.
40+
Click "Open file..." from the start menu on the left side and select the `example.json` file.
4441

42+
![wpa-open-file #center](figures/wpa-open-file.png)
43+
44+
When you click `Open`, the output file is checked for compatibility with the WPA plugin, and the main WPA window opens up.
4545

4646
### Timeline
4747

48-
The WindowsPerf timeline feature (command line option -t) enable continuous counting of Performance Monitoring Unit (PMU) events.
49-
Users can specify sleep intervals (with -i) between counts and set the number of repetitions (with -n), allowing for detailed and flexible data collection.
50-
Users can take advantage of the `WindowsPerf WPA Plugin` to visualize these complex measurements.
51-
This plugin allows for detailed graphical representation of the PMU event data in WPA.
48+
The WindowsPerf timeline feature (command line option -t) enables continuous counting of Performance Monitoring Unit (PMU) events.
49+
50+
You can specify sleep intervals (with -i) between counts and set the number of repetitions (with -n), allowing for detailed and flexible data collection.
5251

53-
For this example we will be running the following command:
52+
You can use WPA to visualize PMU events in the recorded data.
53+
54+
To try the timeline feature, run the command:
5455

5556
```command
5657
wperf stat -m dcache -c 0,1,2,3,4,5,6,7 -t -i 0 -n 50 --json
5758
```
5859

59-
Importing the generated output in WPA will show us the following graph:
60-
![timeline-by-core](figures/timeline-by-core.png)
60+
Open the generated output (`.json` file) in WPA to see the graph:
6161

62-
We can change the default grouping from `Group by core` to `Group by event` to see the following graph instead:
63-
![timeline-by-event](figures/timeline-by-event.png)
62+
![timeline-by-core #center](figures/timeline-by-core.png)
6463

65-
The WindowsPerf WPA Plugin also generates a graph per event note in order to provide a more in-depth grouping of events. To see all the generated graphs we can expand the `Counting timeline` section in the graph explorer section of WPA.
64+
You can change the default grouping from `Group by core` to `Group by event` and see the following graph:
6665

67-
For this example, the following command was used instead:
66+
![timeline-by-event #center](figures/timeline-by-event.png)
6867

69-
```command
68+
The WPA plugin also generates a graph per event note in order to provide a more in-depth grouping of events.
69+
70+
To see all the generated graphs you can expand the `Counting timeline` section in the graph explorer section of WPA.
71+
72+
Run another `wperf` command with different options:
73+
74+
```console
7075
wperf stat -t -i 0 -m imix,l1d_cache_miss_ratio,l1d_cache_mpki,l1d_tlb_miss_ratio,l1d_tlb_mpki -e inst_spec,vfp_spec,ld_spec,st_spec -c 1 --json
7176
```
7277

73-
![timeline-events-by-key](figures/timeline-events-by-key.png)
78+
The graph after opening the `.json` file is shown below:
79+
80+
![timeline-events-by-key #center](figures/timeline-events-by-key.png)
7481

75-
We can double click on any graph to expand it under the Analysis tab for further data visualization.
82+
You can double click on any graph to expand it under the Analysis tab for further data visualization.
7683

7784
### Telemetry
7885

79-
The `WindowsPerf WPA Plugin` also allows the visualization of [Arm telemetry metrics](https://developer.arm.com/documentation/109542/0100/About-Arm-CPU-Telemetry-Solution) counted similarly to counting events.
86+
The WPA Plugin also provides visualization of [Arm telemetry metrics](https://developer.arm.com/documentation/109542/0100/About-Arm-CPU-Telemetry-Solution).
8087

81-
For this example, the following command was used:
88+
To visualize telemetry, run the following command:
8289

83-
```command
90+
```console
8491
wperf stat -t -i 0 -m imix,l1d_cache_miss_ratio,l1d_cache_mpki,l1d_tlb_miss_ratio,l1d_tlb_mpki -e inst_spec,vfp_spec,ld_spec,st_spec -c 1 --json
8592
```
8693

87-
Similarlry to the graphs generated per event note for timeline events, we can also see the generated telemetry timeline graphs under the grapher explorer level in WPA. These graphs are generated dynamically so only the relevant metrics for the given `.json` output file are visible.
94+
You can also see the telemetry timeline graphs under the graph explorer level in WPA.
95+
96+
These graphs are generated dynamically so only the relevant metrics for the given `.json` output file are visible.
8897

89-
![telemetry-preview](figures/telemetry-preview.png)
98+
![telemetry-preview #center](figures/telemetry-preview.png)
9099

91100
Once expanded, a more in-depth view is visible under the Analysis tab of WPA.
92101

93-
![telemetry-table](figures/telemetry-table.png)
102+
![telemetry-table #center](figures/telemetry-table.png)
103+
104+
You now have a basic understanding of how to use `wperf` generated data in the Windows Performance Analyzer.

0 commit comments

Comments
 (0)