NVIDIA DOCA DPA Statistics Tool
DOCA dpa-statistics
is a CLI
tool which allows users to monitor and obtain statistics on thread execution per running DPA process and thread. The tool is used to expose information about the running DPA processes and threads and to collect statistics on DPA thread performance.
The tool presents performance information for running DPA threads, including the number of cycles and instructions executed in a time period. The tool enables initiating and stopping collection of statistics and displaying the data collected per thread.
The process ID output of the dpa-ps
tool may be used as the input parameter for the dpa-statistics
tool.
This tool is supported for NVIDIA® BlueField®-3 only.
The command collect
works on four mutually exclusive modes:
Enable mode – start collecting performance data
Disable mode – stop collecting performance data
Timeout mode – start collecting, wait with a timeout, stop collect and print info. User could break the wait with Ctrl-C command and then the timeout will be canceled and tool will disable statistics collection and prints the info with the actual time of the collect operation.
Infinite mode – no special flags. Same as timeout mode but with infinite timeout. The tool awaits the Ctrl-C command to stop.
The following table lists the collect
command's flags and arguments:
Short Option |
Long Option |
Description |
|
|
Help information |
|
|
Device interface name (MST/RDMA) |
|
|
Hexadecimal process ID for filtering Info
This flag indicates a specific command for the command to operate on. Otherwise, statistics are collected from all processes.
|
|
|
Suppress print header info |
|
|
Enable collect info |
|
|
Disable collect info |
|
|
Enable collect, wait with timeout, disable collect and print info Info
Timeout value is in milliseconds.
Examples for inputting timeout value:
|
|
|
Reset counters before operation starting collect operation |
Presenting performance statistics is applicable after initiating data collection.
The following table lists the show
command's flags and arguments:
Short Option |
Long Option |
Description |
|
|
Help information |
|
|
Device interface name (MST/RDMA) |
|
|
Hexadecimal process ID for filtering |
|
|
Suppress print header info |
Output example:
$ sudo ./dpa-statistics show -d mlx5_0 -p 1
ProcessID Process Name
ThreadID Cycles Instruction Time Executions Thread Name
1 PROCESS_1
3 266268 18193 164 41 EH_1_0_0
4 411571 32727 252 47 EH_1_1_1
Where:
ProcessID
– Thedpa_process_object_id
to which the thread belongsProcess Name
– Thedpa_process_name
to which the thread belongsThreadID
– DPA thread object IDCycles
– Total EU cycles the thread usedInstruction
– Total number of instructions the thread executedTime
– Total time in ticks the thread was activeExecutions
– Total number of thread invocationsThread Name
– Thedpa_thread_name
Examples
Example of
collect
in infinite mode for process 0 with suppress header info:$ sudo ./dpa-statistics collect -d mlx5_0 -p 0 -i ...^C Data collected for 4606 milliseconds 0 nanoseconds 0 PROCESS_0 5 223964 13754 140 31 EH_0_5_5 6 190130 13754 114 31 EH_0_6_6
Example of
collect
in timeout mode with a timeout of 1 second and half a millisecond.$ sudo ./dpa-statistics collect -d mlx5_0 -t 1000.500 Data collected for 1000 milliseconds 500000 nanoseconds ProcessID Process Name ThreadID Cycles Instruction Time Executions Thread Name 0 PROCESS_0 5 223964 13754 140 31 EH_0_5_5 6 190130 13754 114 31 EH_0_6_6 1 PROCESS_1 3 266268 18193 164 41 EH_1_3_3 4 411571 32727 252 47 EH_1_4_4 2 PROCESS_2 3 PROCESS_3 0 223205 13754 137 31 EH_3_0_0 1 189896 13754 113 31 EH_3_1_1 2 191796 13754 117 31 EH_3_2_2 4 PROCESS_4
Example of enabling statistics collection with reset of counters.
$ sudo ./dpa-statistics collect -d mlx5_0 -n -r
Example of disabling statistics collection.
$ sudo ./dpa-statistics collect -d mlx5_0 -o
Reading large statistics counter blocks takes a long time
The
dpa-ps
anddpa-statistics
tools cannot be run at the same time on the same device