Skip to main content

Module adapters

Module adapters 

Source
Expand description

DXGI adapter enumeration + D3DKMT LUID→PCI identity (§3.1/§3.3).

Structs§

AdapterInfo
Everything the backend needs about one DXGI adapter — pure data, any OS.

Functions§

bdf_string
Format a D3DKMT ADAPTERADDRESS as the normalized BDF the whole tool keys on: "0000:bb:dd.f", lowercase hex. The struct has no PCI-domain field — client Windows is effectively always domain 0 (§2.5), hence the literal 0000. This is byte-compatible with what normalize_pci_id produces from NVML’s 8-hex-digit-domain form, which is exactly what makes first-wins dedupe work.
synthetic_device_id
Fallback DeviceId when the D3DKMT address query fails (§3.1): wddm:<vendor>:<device>:<ordinal>. The wddm: prefix is not hex, so normalize_pci_id correctly refuses to dedupe it — listing a device twice beats wrongly merging two. Stable within a session only; good enough for a degraded “device-level only with synthetic id” state.
vendor_of
PCI vendor-id → vendor. Pure, tested on any OS. Unknown ids (including 0x1414 Microsoft, whose software adapters are skipped before this is ever consulted) map to Unknown — which renders as the honest generic “GPU”.