I just release the first package of qemu-virgl which is a build of the latest QEMU git version (see https://www.qemu.org/) with ebaled SDL2 and GTK3 support by default. The package is also built against the last virglrenderer library from https://virgil3d.github.io/ to provide full 3D acceleration inside the VM.
I was able to test on intel and nvidia systems but due to lacking a recent amdgpu based machine I could not test in such an environment. I would appreciate if someone with such hardware could give it a spin and give some feedback here.
To install it:
sudo snap install qemu-virgil
Manually connect the kvm interface:
sudo snap connect qemu-virgil:kvm
Download an ubuntu-core image:
http://cdimage.ubuntu.com/ubuntu-core/16/edge/current/ubuntu-core-16-amd64.img.xz
and unxz it …
Then you can run a vm like:
qemu-virgil -enable-kvm -m 1024 -device virtio-vga,virgl=on -display sdl,gl=on -redir tcp:10022::22 ubuntu-core-16-amd64.img
This shoudl spin up a core VM … run through the configuration and then you can talk to the system via ssh:
ssh -p 10022 localhost
To check if virgl is working:
dmesg|grep virgl
[ 2.411299] [drm] virgl 3d acceleration enabled
If that works you can i.e. install mir-kiosk and mir-kiosk-apps --beta to actually make use of the accelerated graphics.
(do not forget to “snap connect mir-kiosk-apps:wayland-socket-dir mir-kiosk:wayland-socket-dir”, else the apps will not start)