Add mixed-vendor GPU summary and fix startup heap corruption
Collect AMD amdgpu sysfs and optional NVIDIA nvidia-smi stats in the background, auto-detecting supported adapters in PCI order and rotating additional pairs alongside CPU/RAM. Explicit PCI selection and off mode remain supported; missing metrics render as N/A. Initialize the bitmap-only canvas locally instead of the ABI-dependent libg15render initializer: the installed TTF-enabled renderer wrote an 8-byte FreeType pointer past the smaller bitmap-only allocation, corrupting the heap before GPU threads started. Add collector, rendering and full-main regression tests.
This commit is contained in:
1 parent
076641c867
commit
7c06a8089d
12 files changed
+1417
-4
No files matched your search
+34
@@ -30,6 +30,40 @@ Requirements
|
||||
|
||||
- libgtop
|
||||
|
||||
GPU monitoring
|
||||
--------------
|
||||
|
||||
The summary automatically collects ALL supported PCI addresses (amdgpu or nvidia),
|
||||
including mixed vendors. ``--gpu dddd:bb:ss.f`` (alias ``-gpu``) selects
|
||||
a card; ``--gpu off`` disables collection and restores the original layout.
|
||||
``--gpu auto`` is the default. Intel, nouveau and radeon are not supported.
|
||||
Missing metrics show N/A. No supported GPU in auto mode leaves the layout intact.
|
||||
An explicitly selected missing card keeps an N/A column. Selection is at startup.
|
||||
|
||||
Each column shows vendor/index and PCI bus:slot.function, UTL %, U used VRAM, T total VRAM, and TEM in C on five
|
||||
lines. VRAM uses explicit MiB/GiB units (TiB/PiB if needed), with one decimal.
|
||||
One GPU retains summary labels and shortened graphs. Two GPUs appear together
|
||||
beside compact CPU/RAM-used/RAM-total/SWP rows (plus GPU count in five-row mode).
|
||||
RAM also has explicit units. More than two cycle in PCI-sorted pairs every five
|
||||
seconds from startup; all continue collecting. NV1/AMD2-style indices are one-based
|
||||
selected-inventory positions, mapped to full PCI addresses in startup diagnostics.
|
||||
The 64-card bound fails explicitly on overflow. The bottom bar and other screens
|
||||
are unchanged. AMD APU VRAM may mean its reserved
|
||||
carveout, not all shared system memory.
|
||||
|
||||
AMD uses read-only PCI-device sysfs/hwmon files. NVIDIA uses the optional
|
||||
``/usr/bin/nvidia-smi`` without a shell or SDK dependency. Independent AMD workers
|
||||
and one PCI-keyed all-NVIDIA query wait two seconds between samples, with a shared
|
||||
750ms NVIDIA deadline and per-card five-second cache expiry. Shutdown has one
|
||||
one-second worker join/reap budget. Display refresh remains controlled by ``-r``. See README for
|
||||
exact layout, interfaces and subprocess lifecycle details. Run as an ordinary user.
|
||||
|
||||
``make check`` covers GPU-off, single-card and multi-card native framebuffers.
|
||||
Final GPU, vertical TOTAL and time-footer glyphs are checked against font bitmap
|
||||
bits independently of the text renderer. See README for packed framebuffer
|
||||
exports and ``tests/render-images.sh``, which generates verified native/nearest-8x
|
||||
PNGs and narrow contact sheets without cropping the LCD area.
|
||||
|
||||
=======
|
||||
Options
|
||||
=======
|
||||
|
||||
Reference in new issue
Block a user