Skip to content

Commit dbb877a

Browse files
RMelimsimberg
andauthored
Improve Linaro DDT docs (#72)
* improve linaro ddt docs * owner * Update docs/software/devtools/linaro/index.md Co-authored-by: Mikael Simberg <[email protected]> * uniform note * Update docs/software/devtools/linaro/linaro-map.md * Update docs/software/devtools/linaro/index.md * flatten * Update .github/CODEOWNERS * performance analysis tool * owner --------- Co-authored-by: Mikael Simberg <[email protected]>
1 parent 55f9b38 commit dbb877a

File tree

6 files changed

+107
-53
lines changed

6 files changed

+107
-53
lines changed

.github/CODEOWNERS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
* @bcumming @msimberg @RMeli
22
docs/services/firecrest @jpdorsch @ekouts
33
docs/software/communication @msimberg
4+
docs/software/devtools/linaro @jgphpc
45
docs/software/prgenv/linalg.md @finkandreas @msimberg
56
docs/software/sciapps/cp2k.md @abussy @RMeli

docs/software/devtools/index.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
[](){#ref-software-devtools}
22
# Debugging and Performance Analysis tools
33

4-
Debugging and Performance Analysis tools can assist users in developing and optimizing scientific parallel applications, especially in a high-performance computing (HPC) environment.
5-
Efficient tools can significantly improve workflows and save valuable computational resources.
4+
Debugging and performance analysis tools can assist users in developing and optimizing scientific parallel applications, especially in a high-performance computing (HPC) environment.
5+
These tools can significantly improve workflows and save valuable computational resources.
66

7-
CSCS provides debuggers and performance analysis tools on Alps Clusters.
7+
CSCS provides debuggers and performance analysis tools on [Alps][ref-alps] clusters.
88

9-
!!! note "get in touch"
9+
!!! note "Get in touch"
1010
If you have issues or questions about debugging or performance analysis tools, please do not hesitate to [contact us][ref-get-in-touch].
1111

1212
[](){#ref-devtools-debug}

docs/software/devtools/linaro-ddt.md

Lines changed: 20 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@
22
# Linaro DDT
33

44
DDT allows source-level debugging of Fortran, C, C++ and Python codes.
5-
It can be used for debugging serial, multi-threaded (OpenMP), multi-process (MPI) and accelerated (CUDA, OpenACC) programs running on research and production systems, including the CSCS Alps system.
5+
It can be used for debugging serial, multi-threaded (OpenMP), multi-process (MPI), and accelerated (CUDA, OpenACC) programs running on research and production systems, including the CSCS [Alps][ref-alps] system.
66
DDT can be executed either with its graphical user interface or from the command-line.
77

88
!!! note
9-
Linaro DDT is provided in the `linaro-forge` uenv.
10-
Before using DDT, please read the [`linaro-forge` documentation][ref-uenv-linaro], which explains how to download and set up the latest version and set it up.
9+
Linaro DDT is provided in the `linaro-forge` [uenv][ref-uenv].
10+
Before using DDT, please read the [`linaro-forge` uenv documentation][ref-uenv-linaro], which explains how to download and set up the latest version.
1111

1212
## User guide
1313

@@ -27,29 +27,33 @@ mpicxx -g test_cpu.cpp test_gpu.o -o myexe
2727
### Launch Linaro DDT
2828

2929
To use the DDT client with uenv, it must be launched in `Manual Launch` mode
30-
(assuming that it is connected to Alps via `Remote Launch`):
30+
(assuming that it is connected to [Alps][ref-alps] via `Remote Launch`):
3131

32-
=== "on local machine"
32+
=== "On local machine"
3333

3434
Start DDT, and connect to the target cluster using the drop down menu for `Remote Launch`.
35+
If you don't have a target cluster,
36+
the [`linaro-forge` uenv documentation][ref-uenv-linaro] explains how to set up the connection the first time.
3537

36-
Click on `Manual launch`, set the number of processes to listen to, then wait for the slurm job to start (see the "on Alps" tab).
38+
Click on `Manual launch`, set the number of processes to listen to, then wait for the Slurm job to start
39+
(see the "on Alps" tab for how to start the Slurm job).
3740

3841
<img src="https://raw.githubusercontent.com/jgphpc/cornerstone-octree/ddt/scripts/img/ddt/0.png" width="600" />
3942

40-
=== "on Alps"
43+
=== "On Alps"
4144

4245
Log into the system and launch with the `srun` command:
4346

4447
```console
45-
# start a session with both the PE used to build your application
46-
# and the linaro-forge uenv mounted
47-
$ uenv start prgenv-gnu/24.11:v1,linaro-forge/24.1.1:v1 --view=prgenv-gnu:default
48+
$ uenv start prgenv-gnu/24.11:v1,linaro-forge/24.1.1:v1 --view=prgenv-gnu:default # (1)!
4849
$ source /user-tools/activate
49-
5050
$ srun -N1 -n4 -t15 -pdebug ./cuda_visible_devices.sh ddt-client ./myexe
5151
```
5252

53+
1. Start a session with both the uenv used to build your application and the `linaro-forge` uenv mounted.
54+
55+
56+
5357
### Start debugging
5458

5559
By default, DDT will pause execution on the call to `MPI_Init`:
@@ -65,14 +69,16 @@ There are two mechanisms for controlling program execution:
6569

6670
=== "Stop at"
6771

68-
Execution can be paused in every CUDA kernel launch by activating the default breakpoints from the Control menu:
72+
Execution can be paused in every CUDA kernel launch by activating the default breakpoints from the `Control` menu:
6973

7074
<img src="https://raw.githubusercontent.com/jgphpc/cornerstone-octree/ddt/scripts/img/ddt/4.png" width="400" />
7175

7276

73-
This screenshot shows a debugging session on 128 gpus:
77+
??? example "Debugging with 128 GPUs"
78+
79+
This screenshot shows a debugging session on 128 GPUs:
7480

75-
![DDTgpus](https://raw.githubusercontent.com/jgphpc/cornerstone-octree/ddt/scripts/img/ddt/5.png)
81+
![DDTgpus](https://raw.githubusercontent.com/jgphpc/cornerstone-octree/ddt/scripts/img/ddt/5.png)
7682

7783
More informations regarding how to use Linaro DDT are provided in the Forge [User Guide](https://docs.linaroforge.com/latest/html/forge/index.html).
7884

docs/software/devtools/linaro-map.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@ In the first case, the user can set the profiling configuration using the GUI an
77
In the latter (recommended) case, the user can use the MAP executable to launch the application they want to profile which will generate a report file that can then be opened from the locally installed [client](https://docs.linaroforge.com/latest/html/forge/forge/installing/mac_install.html).
88

99
!!! note
10-
Linaro Map is provided in the `linaro-forge` uenv.
11-
Before using Map, please read the [`linaro-forge` documentation][ref-uenv-linaro], which explains how to download and set up the latest version and set it up.
10+
Linaro MAP is provided in the `linaro-forge` [uenv][ref-uenv].
11+
Before using MAP, please read the [`linaro-forge` uenv documentation][ref-uenv-linaro], which explains how to download and set up the latest version.
1212

1313
## Linaro Forge MAP
1414

Lines changed: 77 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,22 @@
11
[](){#ref-uenv-linaro}
22
# Linaro Forge
33

4-
[Linaro Forge](https://docs.linaroforge.com/latest/html/forge/index.html) is a suite of profiling and debugging tools, that includes the DDT debugger and the MAP profiler.
4+
[Linaro Forge](https://docs.linaroforge.com/latest/html/forge/index.html) is a suite of profiling and debugging tools, that includes the DDT debugger and the MAP performance analysis tool.
55

6-
!!! note
6+
!!! note "Linaro DDT debugger and Linaro MAP performance analysis tool"
77
We have separate user guides for the tools provided by the `linaro-forge` uenv.
88
The documentation here shows how to download the uenv, and how to set up your environment.
99

1010
Once you are set up, follow the specific guides:
1111

12-
* the [DDT debugger][ref-devtools-ddt]
13-
* the [MAP profiler][ref-devtools-map].
12+
* [DDT debugger][ref-devtools-ddt],
13+
* [MAP performance analysis tool][ref-devtools-map].
1414

1515
## Quickstart guide
1616

17-
The Linaro uenv is named `linaro-forge`, and the available versions can be determined using the `uenv image find` command:
17+
The Linaro [uenv][ref-uenv] is named `linaro-forge`, and the available versions can be determined using the `uenv image find` command, as explained in the [uenv documentation][ref-uenv].
1818

19-
!!! example "finding available linaro-forge versions"
19+
??? example "Finding available `linaro-forge` versions"
2020

2121
```console
2222
$ uenv image find linaro-forge
@@ -32,21 +32,22 @@ This uenv is configured to be mounted in the `/user-tools` path so that they can
3232
When using alongside another uenv, start a uenv session with both uenv.
3333
In the following example, the `prgenv-gnu` and `linaro-forge` uenv will be mounted at `/user-environment` and `/user-tools` respectively:
3434

35-
```bash
36-
> uenv start prgenv-gnu/24.11,linaro-forge/24.1.1 \
35+
```console
36+
$ uenv start prgenv-gnu/24.11,linaro-forge/24.1.1 \
3737
--view=prgenv-gnu:default,forge
3838

39-
# test that everything has been mounted correctly
40-
# (will give warnings if there are problems)
41-
> uenv status
39+
$ uenv status # (1)!
4240

43-
# check that ddt is in the path
44-
> ddt --version
41+
$ ddt --version # (2)!
4542
Linaro DDT Part of Linaro Forge.
4643
Copyright (c) 2023-2024 Linaro Limited. All rights reserved.
4744
Version: 24.1.1
4845
```
4946

47+
1. Test that everything has been mounted correctly by looking at `uenv status`.
48+
There will be warnings if there are problems.
49+
2. Check that the [DDT debugger][ref-devtools-ddt] is in the path.
50+
5051
!!! note
5152
The `linaro-forge` uenv is always mounted at the `/user-tools` mount point, and a script `/user-tools/activate` is provided to load both ddt and map into your environment, without needing to use a view.
5253

@@ -61,64 +62,108 @@ Version: 24.1.1
6162

6263
### Install and configure the Linaro client on your local machine
6364

64-
We recommend installing the [desktop client](https://www.linaroforge.com/downloadForge) on your local workstation/laptop.
65+
We recommend installing the [Linaro desktop client] on your local workstation or laptop.
6566
It can be downloaded for a selection of operating systems.
66-
The client can be configured to connect with the debug jobs running on Alps, offering a better user experience compared to running with X11 forwarding.
67+
68+
!!! warning
69+
70+
Make sure you download the [Linaro desktop client] matching the version of the `linaro-forge` uenv you are planning to use.
71+
72+
!!! example "Mismatched desktop client and uenv versions"
73+
Mismatches between the client and the uenv version will lead to the following error when trying to establish a remote connection:
74+
75+
```
76+
The local version of Linaro DDT (24.0.6) is not compatible with the remote version (24.1.1).
77+
```
78+
79+
The client can be configured to connect with the debug jobs running on [Alps][ref-alps], offering a better user experience compared to running with X11 forwarding.
6780
Once installed, the client needs to be configured to connect to the vCluster on which you are working.
6881

6982
First, start the client on your laptop:
7083

7184
=== "Linux"
7285

73-
The path will change if you have installed a different version, or if it has been installed in a non-standard installation location.
86+
!!! warning
87+
88+
The path will change if you have installed a different version, or if it has been installed in a non-standard installation location.
7489

7590
```bash
7691
$HOME/linaro/forge/24.1.1/bin/ddt
7792
```
7893

79-
=== "MacOS"
94+
=== "macOS"
8095

81-
The path will change if you have installed a different version, or if it has been installed in a non-standard installation location.
96+
!!! warning
97+
98+
The path will change if you have installed a different version, or if it has been installed in a non-standard installation location.
99+
Please use the appropriate path and version for your installation.
82100

83101
```bash
84102
open /Applications/Linaro\ Forge\ Client\ 24.1.1.app/
85103
```
86104

87105
Next, configure a connection to the target system.
88-
Open the *Remote Launch* menu and click on *configure* then *Add*.
106+
Open the `Remote Launch` menu and click on `Configure...` then `Add`.
89107
Examples of the settings are below.
90108

91109
=== "Daint"
110+
111+
!!! warning
112+
113+
The `Remote Installation Directory` will change if you are using a different version of the `linaro-forge` uenv.
114+
Please use the appropriate version for your setup.
92115

93116
| Field | Value |
94117
| ----------- | --------------------------------------- |
95118
| Connection | `daint` |
96119
97120
| Remote Installation Directory | `uenv run linaro-forge/24.1.1:/user-tools -- /user-tools/env/forge/` |
121+
| Private Key | `~/.ssh/cscs-key` |
98122

99123
=== "Santis"
124+
125+
!!! warning
126+
127+
The `Remote Installation Directory` will change if you are using a different version of the `linaro-forge` uenv.
128+
Please use the appropriate version for your setup.
129+
100130

101131
| Field | Value |
102132
| ----------- | --------------------------------------- |
103133
| Connection | `santis` |
104134
105135
| Remote Installation Directory | `uenv run linaro-forge/24.1.1:/user-tools -- /user-tools/env/forge/` |
136+
| Private Key | `~/.ssh/cscs-key` |
106137

107138
=== "Clariden"
139+
140+
!!! warning
141+
142+
The `Remote Installation Directory` will change if you are using a different version of the `linaro-forge` uenv.
143+
Please use the appropriate version for your setup.
144+
108145

109146
| Field | Value |
110147
| ----------- | --------------------------------------- |
111148
| Connection | `clariden` |
112149
113150
| Remote Installation Directory | `uenv run linaro-forge/24.1.1:/user-tools -- /user-tools/env/forge/` |
151+
| Private Key | `~/.ssh/cscs-key` |
114152

115153
=== "Eiger"
154+
155+
!!! warning
156+
157+
The `Remote Installation Directory` will change if you are using a different version of the `linaro-forge` uenv.
158+
Please use the appropriate version for your setup.
159+
116160

117161
| Field | Value |
118162
| ----------- | --------------------------------------- |
119163
| Connection | `eiger` |
120164
121165
| Remote Installation Directory | `uenv run linaro-forge/24.1.1:/user-tools -- /user-tools/env/forge/` |
166+
| Private Key | `~/.ssh/cscs-key` |
122167

123168
!!! tip
124169

@@ -129,16 +174,16 @@ Some notes on the examples above:
129174

130175
* SSH forwarding via `ela.cscs.ch` is used to access the cluster;
131176
* replace the username `cscsusername` with your CSCS user name that you would normally use to open an SSH connection to CSCS;
132-
* `Remote Installation Path` is pointing to the install directory of ddt inside the image;
177+
* `Remote Installation Directory` is pointing to the install directory of DDT inside the uenv image;
133178
* private keys should be the ones generated for CSCS MFA, and this field does not need to be set if you have added the key to your [SSH agent][ref-ssh-agent].
134179

135180
Once configured, test and save the configuration:
136181

137-
1. check whether the configuration is correct, click `Test Remote Launch`.
138-
2. Click on `ok` and `close` to save the configuration.
139-
3. You can now connect by going to `Remote Launch` and choose the `Alps` entry.
182+
1. check whether the configuration is correct by clicking `Test Remote Launch` (and then `OK` when the test is successful),
183+
2. click on `OK` and then `Close` to save the configuration.
184+
3. You can now connect by going to `Remote Launch` and choose the entry (`Connection` name) you added.
140185
If the client fails to connect, look at the error message, check your SSH
141-
configuration and make sure you can ssh without the client.
186+
configuration and make sure you can SSH without the client.
142187

143188
[](){#ref-uenv-linaro-troubleshooting}
144189
## Troubleshooting
@@ -149,12 +194,16 @@ Notes about known issues.
149194

150195
If the tool fails to launch with the following error message:
151196

152-
Error communicating with Licence Server velan.cscs.ch:
153-
The proxy type is invalid for this operation
154-
Attempting again while ignoring proxies.
197+
```
198+
Error communicating with Licence Server velan.cscs.ch:
199+
The proxy type is invalid for this operation
200+
Attempting again while ignoring proxies.
201+
```
155202

156203
Proxy environment variables need to be set to let the tool connect to the license server, as explained in [Compute node proxy configuration][ref-guides-internet-access].
157204

158205
!!! note "AMD GPU support"
159206

160-
CSCS does not currently have a Linaro license for AMD gpus.
207+
CSCS does not currently have a Linaro license for AMD GPUs.
208+
209+
[Linaro desktop client]: https://www.linaroforge.com/downloadForge

mkdocs.yml

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -72,12 +72,10 @@ nav:
7272
- 'Python with pip': build-install/pip.md
7373
- 'Debugging and Performance Analysis':
7474
- software/devtools/index.md
75-
- 'Linaro Forge uenv': software/devtools/linaro-forge.md
76-
- 'Linaro MAP': software/devtools/linaro-map.md
77-
- 'Linaro DDT': software/devtools/linaro-ddt.md
75+
- 'Linaro uenv': software/devtools/linaro-uenv.md
76+
- 'Using Linaro performance analysis tool': software/devtools/linaro-map.md
77+
- 'Using Linaro debugger': software/devtools/linaro-ddt.md
7878
- 'NVIDIA Nsight': software/devtools/nvidia-nsight.md
79-
#- 'Debugging': software/devtools/debug/index.md
80-
#- 'Performance Analysis': software/devtools/perf/index.md
8179
- 'uenv': software/uenv.md
8280
- 'Container Engine': software/container-engine.md
8381
- 'Services':

0 commit comments

Comments
 (0)