You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When profiling in the command line mode, the `proton.start` and `proton.finalize` functions are automatically called before and after the script execution. Any `proton.start` and `proton.finalize` functions in the script are ignored. Also, in the command line mode, only a single *session* is supported. Therefore, `proton.deactivate(session_id=1)` is invalid, while `proton.deactivate(session_id=0)` is valid.
@@ -156,6 +157,23 @@ More options can be found by running the following command.
156
157
proton-viewer -h
157
158
```
158
159
160
+
### Advanced features
161
+
In addition to profiling, Proton also incorporates MLIR/LLVM based compiler instrumentation passes to get Triton level analysis
162
+
and optimization information. This feature is under active development and the list of available passes is expected to grow.
163
+
164
+
#### Available passes
165
+
print-mem-spaces: this pass prints the load and store address spaces (e.g. global, flat, shared) chosen by the compiler and attributes back to Triton source information.
166
+
167
+
Example usage with the Proton matmul tutorial:
168
+
```bash
169
+
$ proton --instrument=print-mem-spaces matmul.py
170
+
0 matmul_kernel matmul.py:180:20 SHARED STORE
171
+
1 matmul_kernel matmul.py:181:20 SHARED STORE
172
+
2 matmul_kernel matmul.py:180:20 SHARED LOAD
173
+
3 matmul_kernel matmul.py:181:20 SHARED LOAD
174
+
```
175
+
Notes: The instrument functionality is currently only available from the command line. Additionally the instrument and profile command line arguments can not be use simulantously.
176
+
159
177
### Instruction sampling (experimental)
160
178
161
179
Proton supports instruction sampling on NVIDIA GPUs.
0 commit comments