Overview of PVRPerfServer

PVRPerfServer is a console application for Android, Linux, QNX, Tizen, Windows operating systems (OS). It reads timing and counter data from the PowerVR hardware on a device, and also CPU and memory consumption data from the OS.

PVRPerfServer also acts as an intermediary for applications that make use of certain PVRScope library functionality that require communication with PVRTune, such as PVRScopeComms.

Requirements

For PVRPerfServer to read hardware data correctly, the driver must have performance profiling enabled. In many cases this functionality is enabled by default. This can be checked by confirming the existence on the platform of libPVRScopeServices.so, PVRScopeServices.dll, or an equivalent. If PVRPerfServer fails to initialise, it is possible that performance profiling support has been removed from the device drivers.

Linux and Android access to /proc filesystem

On Android, this is more likely to succeed when using the CLI version of PVRPerfServer, as the APK version may not have the required permissions to access the /proc filesystem. The CLI version of PVRPerfServer can be run from an adb shell, and may require root access to read certain files.

IO delay

For PVRPerfServer to read per-PID IO delay from the file /proc/[PID]/stat it may be necessary to enable (both at Kernel build time and runtime) the data. See https://www.kernel.org/doc/html/latest/accounting/delay-accounting.html#usage. Here’s a Linux example that purges the disk cache (but only so that find gives high IO load for this example) then enables the data while recording a .PVRTune file:

echo 3 | sudo tee /proc/sys/vm/drop_caches
sudo sysctl kernel.task_delayacct=1
./PVRPerfServer/PVRPerfServerComplete --exec "find / -name *servers*" --sendto find.pvrtune
sudo sysctl kernel.task_delayacct=0

Pressure Stall Information (PSI)

PVRPerfServer reads Pressure Stall Information (PSI) information from the /proc/pressure filesystem. The PSI information is not available on all kernels, and may need to be enabled at kernel build time; for more information see https://www.kernel.org/doc/html/latest/accounting/psi.html and the Kernel build option CONFIG_PSI. Typically this includes the “cpu”, “io”, and “memory” files; from kernel 6.1 the “irq” file was added, if the CONFIG_IRQ_TIME_ACCOUNTING kernel build option is enabled.