Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

read the output of nvprof in CUDA

Tags:

cuda

profiler

I am running my program using nvprof to get profile information using the command:

nvprof -o profileOutput -s ./exe args

I wanted information about warp divergence, coalesced read/write, occupancy etc. But when I open the file profileOutput, its in some other format altogether and have weird symbols like @^@^.....

I am opening the file in vim. What is the correct way to see profile information of a CUDA program. Please help.

like image 772
user1439690 Avatar asked Nov 27 '12 09:11

user1439690


People also ask

How does nvprof work?

The nvprof profiling tool collects and views profiling data from the command-line. It enables the collection of a timeline of CUDA-related activities on both CPU and GPU , including kernel execution, memory transfers, memory set and CUDA API calls and events or metrics for CUDA kernels.

What is Nvprof?

Nvprof is a command-line light-weight GUI-less profiler available for Linux, Windows, and Mac OS. This tool allows you to collect and view profiling data of CUDA-related activities on both CPU and GPU, including kernel execution, memory transfers, etc.

What is profiling explain CUDA profiling in details?

Profiling Overview The Visual Profiler is a graphical profiling tool that displays a timeline of your application's CPU and GPU activity, and that includes an automated analysis engine to identify optimization opportunities. The nvprof profiling tool enables you to collect and view profiling data from the command-line.


1 Answers

You don't need -s because it is the default situation by itself.

-o specifies the output file which can be imported later or open by Nvidia visual profiler, which is not human readable.

If you need to compute occupancy you can use this occupancy calculator provided by Nvidia. There's an article about it.

If you need to trace branches you can use profiling in trace mode and trace branches.

like image 67
Aznaveh Avatar answered Oct 16 '22 03:10

Aznaveh