You are not logged in.

#1 2018-08-07 16:47:28

Registered: 2013-11-18
Posts: 15

[qemu] Windows guest video/GPU acceleration: Methods, recommendations

[Preface: I searched this board and the kernel & hardware board but didn't find general information or a summary.]

Use case: Run Windows in a qemu VM in order to run a Windows application which is graphics intensive with sound, and output its display to an external monitor.  (Local display would be handy but isn't required given that I'm thinking about using a discrete GPU.)

I'm a grey-haired sysadmin preparing for the first time to run Windows "gaming" inside a qemu VM.  While there are lots of minor bugs to wrestle with -- sound distortion, passthrough hardware disconnection-related bugs, etc. -- the major focus of high performance approaching bare metal speeds is video/GPU acceleration.  Once you wrap your mind around that, you can choose a video "routing" method, then choose hardware which meets its specific requirements and is reported to work with no or few issues.

I'm still at the "wrapping my mind around" stage.  My reading indicates there are five ways to skin this cat:

1.) QXL video driver and SPICE client for display
2.) PCI VGA/GPU passthrough via OVMF
2B.) "Looking Glass" (see below)
3.) Fully virtualized GPU support for the VM via Intel-specific iGVT-g extension
4.) Virgil3d para-virtualized virtio-gpu device with Windows guest OpenGL video driver

Further information on these methods:

1.) QXL is a high-performance display method but is not designed to offer near-bare metal performance.

2.) PCI VGA passthrough seems to be teh hotness.  This page and forum thread are referenced EVERYWHERE: … h_via_OVMF

Arch Linux -- Best documentation Care AnyWhere!  Good job, Archers :^D

2B.) There is a fairly recent passthrough method called "Looking Glass": … ort/122387

which uses DXGI (MS DirectX Graphics Infrastructure) to pass entire frames captured from the VM's video card through shared memory to the host system where they are read (scraped) by a display client running on the bare-metal host.  Forum posts seem very positive.

3.) This is restricted to Intel graphics (which is likely a performance limitation).  For more info, see: … ntel_gvtg/ … on_Support

4.) I have found very little about this method except the canonical webpages and any links given in them: … irtio.html

Also see here and read the comments: … ows-Guests

I did read one comment on some thread which speculated that this technique hasn't been more widely used because it doesn't work very well.  I simply don't know.

It certainly seems like the best method for now into the near future is to spend on a two-graphics setup (laptop in my case) and to use PCI passthrough.  That would allow me to do what I want with properly chosen hardware.  As a bonus, I could experiment with Looking Glass.

I was naively thinking about an Intel iCPU and an AMD Radeon-type dGPU.  The dGPU will need an HDMI external output for my use case, even though that means the dGPU will be powered and reduce battery life.  Will that beat the pants off GVT-g?  (I think I'll avoid nVidia my first time out because of problem reports I keep stumbling over about nVidia cards in VMs.)

I'm a n00b, not a real gamer.  My questions:

i.) What did I screw up?  What did I miss in my research that's important?  Is my first draft plan above decent, or stupid?

ii.) Is it possible to use the dGPU as render-only and display its output locally at near-bare metals speeds?

iii.) Are there Looking Glass users lurking on this board?  Does it work well?  What hardware is best?

iv.) Is there any use in considering Intel's GVT-g?

v.) Has anyone even tried virtio-gpu with the Widows guest OpenGL video driver developed during GSoC 2017?

Many thanks to all!

Clemmitt Sigler


Board footer

Powered by FluxBB