NVIDIA Tegra
NVIDIA Tegra Linux Driver Package

Development Guide
28.2 Release


 
TegraStats Utility
 
Reported Statistics
Options
Running TegraStats
Re-Deploying TegraStats
The TegraStats utility reports memory and processor usage for NVIDIA® Tegra® devices.
The JetPack installer, or the flashing script, places the script in the home directory on the target at:
${HOME}/tegrastats
On the host system, the script is delivered in the TAR file at:
Linux_for_Tegra/nv_tegra/nv_tools.tbz2
Reported Statistics
The statistics the TegraStats utility reports are as follows:
Statistic
X
Y
Z
RAM X/Y (lfb NxZ)
Largest Free Block (lfb) is a statistic about the memory allocator.
Refers to the largest contiguous block of physical memory that can currently be allocated; at most 4 MB. Can become smaller with memory fragmentation.
The physical allocations in virtual memory can be bigger.
Amount of RAM in use in MB.
Total amount of RAM available for applications.
Z is the size of the largest free block.
N the number of free blocks of this size.
CPU [X%,Y%, , ]@Z
T30 has up to four CPU cores in the G-Cluster.
One CPU core in the LP-Cluster.
Load statistics for each of the CPU cores relative to the current running frequency Z, or 'off' in case a core is currently powered down.
A rough approximation based on time spent in system idle process as reported by the Linux kernel in /proc/stat file.
Load statistics for each of the CPU cores relative to the current running frequency Z, or 'off' in case a core is currently powered down.
A rough approximation based on time spent in system idle process as reported by the Linux kernel in /proc/stat file.
CPU frequency in MHz. Dynamically goes up or down depending on the CPU workload.
APE Audio Processing Engine Y
APE subsystem consists of ADSP (Cortex®-A9 CPU), mailboxes, AHUB, ADMA etc.
N/A
ADSP load activity monitor and reports ADSP frequency in MHz
N/A
edp limit X
TX1: To see EDP limit use
--systrace
Limit of the CPU maximum frequency.
N/A
N/A
emc X%@Y
EMC is the external memory controller, through which all sysmem/carve-out/GART memory accesses go.
Percent of the EMC memory bandwidth being used; relative to the current running frequency.
EMC frequency in MHz
N/A
GR3D X%@Y
GR3D is the GPU engine.
Percent of the GR3D being used; relative to the current running frequency.
GR3D frequency in MHz
N/A
MSENC Y
MSENC is the video hardware encoding engine.
N/A
MSENC frequency in MHz
N/A
NVDEC Y
NVDEC is the video hardware decoding engine.
Shown only when hardware decoder/encoder engine is used.
N/A
NVDEC frequency in MHz
N/A
MTS fg X bg Y
Time spent in foreground tasks.
Time spent in background tasks
N/A
[temp name]@XC
Temperature in Celsius.
N/A
N/A
[VDD_name] X/Y
Current rail voltage.
Average value
N/A
Example Output
The following example provides output from a non-stress system.
RAM 1371/7846MB (lfb 1389x4MB) CPU [2%@345,0%@345,0%@345,0%@345,0%@345,0%@344] EMC_FREQ 7%@102 GR3D_FREQ 0%@114 APE 150 MTS fg 0% bg 0% PLL@36C thermal@36.2C MCPU@36C Tboard@35C AO@36C GPU@42C PMIC@100C BCPU@36C Tdiode@36.5C VDD_IN 2203/2220 VDD_CPU 440/395 VDD_GPU 360/360 VDD_SOC 480/488 VDD_WIFI -82/-82 VDD_DDR 240/240
The following example provides output from a system with a little bit of stress:
 
RAM 2669/7846MB (lfb 1065x4MB) CPU [100%@345,100%@2419,100%@2419,100%@344,11%@346,100%@345] EMC_FREQ 17%@1600 GR3D_FREQ 0%@114 APE 150 MTS fg 0% bg 0% PLL@43C thermal@42.8C MCPU@43C Tboard@40C AO@42.5C GPU@49C PMIC@100C BCPU@43C Tdiode@43.5C VDD_IN 5224/3423 VDD_CPU 844/712 VDD_GPU 360/361 VDD_SOC 884/664 VDD_WIFI -114/-91 VDD_DDR 240/240
Options
TegraStats options and usage are described in the following table.
Option
Description
<delay>
The delay between outputs in milliseconds (ms). For example, a value of 500 causes output to display twice per second. If no delay value is specified, the default delay is 1000 ms. A <delay> value, if specified, must be the first value after the command, before any other options.
--start
Run TegraStats as a daemon, in the background.
--stop
Stop running any running instances of tegrastats.
--logfile <out_file>
Write the output of TegraStats to <out_file>.
-once
Print data only once and then exit.
-throttle
Track the throttle count.
<thermal_zone>
Print temperature in specified <thermal_zone>. The value for <thermal_zone> must match one of the strings in "/sys/devices/virtual/thermal/thermal_zone*/type.
Running TegraStats
When running tegrastats on Linux devices, it prints statistics to stdout.
Example Log Print
RAM 2669/7846MB (lfb 1065x4MB) CPU [100%@345,100%@2419,100%@2419,100%@344,11%@346,100%@345] EMC_FREQ 17%@1600 GR3D_FREQ 0%@114 APE 150 MTS fg 0% bg 0% PLL@43C thermal@42.8C MCPU@43C Tboard@40C AO@42.5C GPU@49C PMIC@100C BCPU@43C Tdiode@43.5C VDD_IN 5224/3423 VDD_CPU 844/712 VDD_GPU 360/361 VDD_SOC 884/664 VDD_WIFI -114/-91 VDD_DDR 240/240
To run tegrastats
On the target, execute the following command:
sudo ${HOME}/tegrastats <delay> &
Where <delay> is the frequency of log prints, expressed in milliseconds (1000 means print every second).
To stop tegrastats
On the target, execute the following command:
sudo ${HOME}/tegrastats --stop
Re-Deploying TegraStats
The TegraStats utility is preinstalled in the default root file system in the home directory. If you modified the root file system configuration and removed tegrastats from the build, you can re-deploy it on the target at runtime.
To re-deploy tegrastats
Execute the following command from the debug host system:
scp tegrastats nvidia@<TARGET_DEVICE_IP>:/home/nvidia/