diff options
author | Christian Göttsche <cgzones@googlemail.com> | 2023-08-29 13:03:31 +0200 |
---|---|---|
committer | cgzones <cgzones@googlemail.com> | 2024-03-27 19:49:23 +0100 |
commit | f8c5bdd86478a852c8d3967630dd81fdd70fa030 (patch) | |
tree | 868c30988bd44ee8e8be487ad2dd22f23e3cc46b /linux/LinuxMachine.h | |
parent | ec608672cea2b857a7b43832bfabae2bbe6c04da (diff) |
Linux: add GPU meter and process column
Based on the DRM client usage stats[1] add statistics for GPU time spend
and percentage utilization.
[1]: https://www.kernel.org/doc/html/latest/gpu/drm-usage-stats.html
Diffstat (limited to 'linux/LinuxMachine.h')
-rw-r--r-- | linux/LinuxMachine.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/linux/LinuxMachine.h b/linux/LinuxMachine.h index 309b4850..398d1d77 100644 --- a/linux/LinuxMachine.h +++ b/linux/LinuxMachine.h @@ -53,6 +53,12 @@ typedef struct CPUData_ { bool online; } CPUData; +typedef struct GPUEngineData_ { + unsigned long long int prevTime, curTime; /* absolute GPU time in nano seconds */ + char* key; /* engine name */ + struct GPUEngineData_* next; +} GPUEngineData; + typedef struct LinuxMachine_ { Machine super; @@ -73,6 +79,9 @@ typedef struct LinuxMachine_ { memory_t availableMem; + unsigned long long int prevGpuTime, curGpuTime; /* total absolute GPU time in nano seconds */ + GPUEngineData* gpuEngineData; + ZfsArcStats zfs; ZramStats zram; ZswapStats zswap; |