Getting Experimental Vulkan Within QEMU VMs Using Linux 5.16+ Paired With Mesa's Venus
Written by Michael Larabel in Virtualization on 26 November 2021 at 11:28 AM EST. 15 Comments
VIRTUALIZATION --
When running on the very latest Linux 5.16 Git kernel paired with recent Mesa and various experimental components to the virtualization stack, it is possible getting at least basic Vulkan acceleration working within QEMU guest virtual machines that in turn is accelerated by the host.

Getting experimental Vulkan API support working within guest virtual machines on QEMU currently requires a number of steps, including the use of yet-to-be-upstreamed code in some areas.

On the kernel side Linux 5.16+ is needed that is still in development. That very latest kernel code is required for VirtIO context types support. Additionally, the kernel must be built with UDMABUF enabled. Mesa 21.1+ is needed but obviously the newer the Mesa code is generally the better experience from performance to new features.

Vulkan in guest VMs also requires a currently branched version of Virglrenderer along with a branched version of QEMU. Hopefully those Virgl and QEMU side changes will be upstreamed soon.

Those wanting to play around with Vulkan in QEMU VMs this weekend using the experimental code can see the build steps via this blog post by Collabora who has been involved with the open-source GPU guest VM support effort.
Related News
About The Author
Author picture

Michael Larabel is the principal author of Phoronix.com and founded the site in 2004 with a focus on enriching the Linux hardware experience. Michael has written more than 20,000 articles covering the state of Linux hardware support, Linux performance, graphics drivers, and other topics. Michael is also the lead developer of the Phoronix Test Suite, Phoromatic, and OpenBenchmarking.org automated benchmarking software. He can be followed via Twitter or contacted via MichaelLarabel.com.

Popular News This Week