Repository navigation
PR 0075 Vulkan select and report the host GPU by UUID
- GitHub state: Merged
- Disposition at review: Merged
-
Current head at review:
3f5446b572e310a3dac76d6403513862b299e768(feature/gpu-adapter-selection) -
Reviewed head:
3f5446b572e310a3dac76d6403513862b299e768 - Last reviewed: 2026-09-14 UTC
-
Base:
mainat4e505bfb821ae326d3129539d559848a34759500 - Subsystem: Vulkan renderer
Review freshness: this page records the final/known PR head at review time. If the PR is reopened or rewritten, re-review before relying on implementation details.
- What it changes: Vulkan: select and report the host GPU by UUID
- Why it was attempted: Observed problem: xemu selected Vulkan devices by display name, silently chose another compatible device when a preference failed, overwrote the saved preference with the observed result, and offered no machine-readable proof of the actual adapter. Profiling evidence: Not applicable. This is deterministic test-control and user-interface work. Suspected cause: Discovery, name-based preference, fallback, and runtime identity were combined in renderer initia…
- Current/final result: Merged: Vulkan adapter selection/reporting is explicit enough to verify the actual initialized physical device.
- Lesson: Renderer benchmarking and compatibility require exact physical-device identity; requested GPU, initialized GPU, capabilities, and reported adapter must agree.
| Implementation file | Δ | Why it matters |
|---|---|---|
config_spec.yml |
+1/-0 | User-facing configuration/toggle schema for the behavior. |
hw/xbox/nv2a/pgraph/pgraph.c |
+32/-4 | Shared PGRAPH guest-state/method handling and renderer boundary. |
hw/xbox/nv2a/pgraph/vk/device-inventory.c |
+92/-0 | Vulkan physical-device discovery, identity, selection, or reporting. |
hw/xbox/nv2a/pgraph/vk/device-inventory.h |
+87/-0 | Vulkan physical-device discovery, identity, selection, or reporting. |
hw/xbox/nv2a/pgraph/vk/device-selection.c |
+189/-0 | Vulkan physical-device discovery, identity, selection, or reporting. |
hw/xbox/nv2a/pgraph/vk/device-selection.h |
+83/-0 | Vulkan physical-device discovery, identity, selection, or reporting. |
hw/xbox/nv2a/pgraph/vk/display.c |
+6/-0 | Display output ownership, reuse, or presentation transport. |
hw/xbox/nv2a/pgraph/vk/glsl.c |
+24/-3 | GLSL→SPIR-V compilation/module construction or backend shader integration. |
hw/xbox/nv2a/pgraph/vk/instance.c |
+212/-61 | NV2A guest-visible state or backend translation path. |
hw/xbox/nv2a/pgraph/vk/meson.build |
+2/-0 | Build registration for new/changed implementation or test units. |
hw/xbox/nv2a/pgraph/vk/renderer.h |
+4/-1 | Renderer-owned state needed by the implementation. |
tests/unit/meson.build |
+15/-0 | Focused/regression validation for the implementation contract. |
tests/unit/test-xbox-vk-device-inventory.c |
+259/-0 | Focused/regression validation for the implementation contract. |
tests/unit/test-xbox-vk-device-selection.c |
+183/-0 | Focused/regression validation for the implementation contract. |
tests/unit/test-xemu-gpu-info.c |
+176/-0 | Focused/regression validation for the implementation contract. |
tests/unit/test-xemu-gpu-launch.c |
+158/-0 | Focused/regression validation for the implementation contract. |
ui/meson.build |
+2/-0 | Build registration for new/changed implementation or test units. |
ui/xemu-gpu-info.c |
+517/-0 | User-facing control or presentation integration. |
ui/xemu-gpu-info.h |
+67/-0 | User-facing control or presentation integration. |
ui/xemu-gpu-launch.c |
+157/-0 | User-facing control or presentation integration. |
ui/xemu-gpu-launch.h |
+55/-0 | User-facing control or presentation integration. |
ui/xemu.c |
+90/-2 | User-facing control or presentation integration. |
ui/xui/main-menu.cc |
+78/-0 | User-facing control or presentation integration. |
flowchart LR
subgraph Before
A[Guest report / DMA request] --> B[Map and validate target] --> C[Queue/write completion] --> D[Guest observes result]
end
subgraph PR_75[PR #75]
E[Guest report / DMA request] --> F[PR #75 bounded rule] --> G[Valid path or explicit reject] --> H[Guest observes result]
end
Add pure UUID parsing, formatting, and deterministic selection policy. - Add checked Vulkan enumeration and unified renderer-capability evaluation. - Add display.vulkan.device uuid without removing legacy name migration. - Add process-local GPU CLI parsing before normal startup side effects. - Add atomic schema-versioned inventory and runtime reports. - Prevent device and renderer substitution in strict mode. - Select glslang SPIR-V output compatible with the selected Vulkan API level. - Report shared presentation only after OpenGL memory import and texture creation succeed. - Add the adapter selector and active adapter readout under Display…
Merged: Vulkan adapter selection/reporting is explicit enough to verify the actual initialized physical device.
Renderer benchmarking and compatibility require exact physical-device identity; requested GPU, initialized GPU, capabilities, and reported adapter must agree.
Do not accept a Vulkan A/B comparison if the candidate may have initialized a different adapter than the reference.
Pointers only; the detailed evidence remains in its original location.
docs/performance/docs/superpowers/plans/docs/superpowers/specs/
DSP tooling guide and navigation updated November 2, 2026 for experimental PR #384, source 8f51d237. Capture/replay usage and limits.
The earlier wiki-wide review was published November 1, 2026. Emulator source: b7140848. Reviewed wiki content: 1d2b671. Current status · Release availability · Publication process.
- Home
- Current status
- Stable versus main
- Implemented mechanisms
- Controls and defaults
- Measured results and limits
- Complete change register
- System
- CPU and vCPU
- Memory and DMA
- Graphics / NV2A
- APU and audio
- Timing and timers
- Platform and I/O
- Hardware observations
- Fidelity boundaries
- Methodology
- PGR2 routes
- Debugging lag / hot paths
- Tools and commands
- DSP capture, replay and fuzzing
- HLE readiness and public XISO proof
- Concurrent DSP shadow and OpenAL proof
- DSP HLE operation inventory
- DSP HLE fix examples and testing
- Development
- Upstream shortlist
- Wiki maintenance
- Research / retired work
- Optimization catalog
- Hot-path shortcuts
- Researched experiments
- Unproven proposal directory
- PR lessons
- September26 snapshot
Repository · PRs · Issues