Expand description
The text Linux gives about its GPUs, parsed (SPEC_STATUS_BAR_GPU_PANEL_2026_11_15.md §3, phase 2): a process’s
/proc/<pid>/fdinfo/<fd> for a DRM device (kernel 5.14 and later; amdgpu, i915, xe), the uevent of a card,
and the PCI id database’s names. Pure text and arithmetic, so every case is a test on any platform; linux.rs
reads the files.
drm-driver: amdgpu
drm-pdev: 0000:03:00.0
drm-client-id: 4083
drm-engine-gfx: 1234567890 ns
drm-memory-vram: 1048576 KiB
drm-memory-gtt: 2048 KiBStructs§
- DrmClient
- One open DRM client (a process’s handle on a GPU), as its fdinfo shows it.
- Scanned
- One DRM file descriptor of one process, read.
Constants§
Functions§
- display_
name - What to call a GPU: the marketing name in the database’s brackets where it has one (
Navi 21 [Radeon RX 6800]), with the vendor in front unless the name carries it; else the database’s name; else the ids. - held_on
- What the clients hold on one GPU (by PCI slot), for an adapter that can’t say itself: Intel’s memory is the machine’s, and only the processes’ own figures add up to how much of it the GPU holds.
- kind_of
- An adapter’s kind from its name and the memory it has of its own (
None: it says none, as Intel’s do). - parse_
fdinfo - A DRM fdinfo’s figures;
Nonefor a file that is not one (nodrm-driverline). - parse_
pci_ id 0x1002(a PCIvendorordevicefile) as a number.- parse_
uevent KEY=valuelines (auevent).- pci_
ids_ device - A device’s name in the PCI id database (
pci.ids: a vendor line at the left edge, its devices one tab in). - process_
figures - Each process’s figures from the clients read, and the busy times to compare with at the next read.
- vendor_
name - The vendor’s short name, for a name the id database gives without one.
Type Aliases§
- Client
Key - A client’s identity across two reads.