Virtio-nvgpu is an experimental open-source project that gives a Linux virtual machine (VM) unusually direct access to an NVIDIA graphics processor (GPU) on the host. Rather than translating each Vulkan or OpenGL command, it forwards requests made to NVIDIA’s kernel driver between the VM and host. That lets the guest run NVIDIA’s own user-mode drivers, including the same Vulkan and NVENC libraries used outside the VM.
The opening paragraph introduces virtio-nvgpu and its role in forwarding NVIDIA kernel-driver requests between a Linux guest and its host.
The design targets headless streaming: a compositor inside the VM renders and encodes video on the GPU, then sends only the compressed video stream to a remote client. In the project’s benchmark on one RTX 3060, frames taking at least about 2 milliseconds were within 2% of bare-metal performance; a 12-second test used 0.37 seconds of CPU in the guest versus 0.40 seconds on the host. The author also ran four 720p vkcube guests simultaneously, each encoding H.264 at 60 Hz, with the combined rate close to one guest’s rate.
The mechanism matters more than those numbers alone. The guest driver passes control requests through a virtqueue, while memory mappings let NVIDIA’s user-mode driver submit rendering work without crossing the VM boundary for every draw call. The host-side device translates driver request parameters and maps guest handles to host device files. This differs from API-level translation, which must serialize and replay many graphics calls, and from dedicating a whole GPU to one VM.
The evidence is narrow and comes from the project’s own README. It covers one synthetic load, principally an RTX 3060 with driver 595.99.02; an RTX A2000 rendered but was not benchmarked. The author says CUDA beyond enumeration is untested, more than four guests have not been tried, and eight guests are unknown. The sandboxed per-guest helper that would hold real device access is only a design note, so the current backend runs inside the virtual-machine monitor’s process.
Driver compatibility is another constraint. NVIDIA’s kernel-driver application binary interface (ABI)—the binary contract used by driver requests—changes between releases. Virtio-nvgpu therefore ships explicit profiles for selected driver ranges and rejects anything older than 535.129.03 rather than guessing at an unknown request layout. The practical promise is efficient GPU sharing for streaming, but the README does not establish production isolation, broad application compatibility, or performance beyond its limited tests.