I am using nvprof to get a metrics csv of an app running on P100.
Here is my command line:
nvprof --csv --metrics all --log-file results.csv ./app
The nvprof will profile the process kernel-wise and I will get a detailed csv file.
I want to profile this app on A100 which doesn’t support nvprof, so I have to use the nsight instead. Is there any way to get the same form of csv by nsight?
I tried the nvprof compatible mode, but it doesn’t work. Thank you!
There is no nvprof compatibility mode in Nsight Compute. You may want to clarify if you are using Nsight Compute or Nsight Systems? The former is for profiling metrics (as in your nvprof command) while the latter is for tracing cpu and gpu activities. The document for Nsight Systems can be found here. For Nsight Compute, the command line flags are explained here and when using ncu --help. There are flags for --csv, --log-file and --page raw.
Hi Felix, thanks for your help. I have one more question. Do you know how can I get the aggregated results? Suppose I have a kernel running inside a loop, in nvprof, the default value will display per kernel, but in ncu, it seems it will show per iterations. Thank you!
You need to specify the values to --metrics without spaces (" are possible, but not required). The correct command line would hence be ncu --csv --print-summary per-kernel --metrics smsp__inst_executed.avg.per_cycle_active,dram__bytes_write.sum.per_second ./app.