Hacker News new | ask | show | jobs
by matxip 2799 days ago
I actually set this up just the other day for my Windows 10 VM. To be clear, the idea here is to run a Windows VM (with near native performance by passing it a hardward graphicical device), then take the output directly from the VM graphics card's memory and feed that to a Linux host where it can display that output natively.

The primary demographic seems to be gamers that want to ditch Windows for Linux, but don't want compromise on performance. I can attest to the performance angle, but it has a number of rough edges.

This project seeks to solve input and output management. For example, I've been used a second monitor and a hardware USB switch, which is attached to my keyboard and mouse, for interacting with my VM. Looking glass actually performs excellently for input capturing for me, but I'm finding the video output just a touch too slow and find myself just switching my monitor input instead. I'm thinking that might have more to do with my using Intel integrated graphics on my host though, but I'm not sure. I'm pretty excited to see where this goes nonetheless.

1 comments

From what I've seen so far it copies every frame via the CPU and that gets quite slow if you want to do it 60 times a second at high resolution.

Optimus etc. use DMA, so you can copy directly between the two devices.

Hopefully looking glass will support that as well in the future. Last time I looked at least nvidias DMA support was officially restricted to quadro only, so not sure it'll actually happen.

Microsoft has support for cross-adapter rendering for (SurfaceBook dGPU is hotpluggable) - where textures are resident in the dGPU memory (when in use) but the render target surface lies in iGPU's memory which directly scans out that surface every vsync.

Technically, it is slightly more complex because of how vsync works but zero copy cross adapter rendering is possible.

I was an intern at the display kernel team this past summer and worked on a similar project for VR displays (which adds further complexity due to late stage reprojection and sensitivity to pipeline latency).