It might be possible, depending on if the screen is connected to the dGPU or iGPU (I’d guess iGPU). I wouldn’t know because I did my setup on a desktop with two dGPUs. I would think it’s possible, but you might need an external monitor (?). I don’t know how Optimus laptops are wired.
Where I started for GPU passthrough, which got me ~90% of the way there, is https://github.com/bryansteiner/gpu-passthrough-tutorial . Gives you the shell scripts, XML, etcetera needed to do it; I had to modify some bits (some of which you can see in issues), but this is my preferred tutorial. Basically, try it, get really frustrated, take a break for a while, get back to it and keep tinkering with it (check permissions, logs, PCIe driver binds, etcetera), and eventually, you’ll figure it out.
I might be able to send over some of my XML to get you started, but I don’t know how helpful that will actually be over the tutorial, as our systems are completely different, and the AMD GPU I use has different bugs/quirks when doing this than Nvidia ones. The truth of the matter on why there’s not really a single-click, easy way to do GPU passthrough is because each system is unique, from the motherboard PCIe implementation to bugs in GPU firmware. That doesn’t mean you shouldn’t try, but it takes a bit of ingenuity.
It might be possible, depending on if the screen is connected to the dGPU or iGPU (I’d guess iGPU). I wouldn’t know because I did my setup on a desktop with two dGPUs. I would think it’s possible, but you might need an external monitor (?). I don’t know how Optimus laptops are wired.
Where I started for GPU passthrough, which got me ~90% of the way there, is https://github.com/bryansteiner/gpu-passthrough-tutorial . Gives you the shell scripts, XML, etcetera needed to do it; I had to modify some bits (some of which you can see in issues), but this is my preferred tutorial. Basically, try it, get really frustrated, take a break for a while, get back to it and keep tinkering with it (check permissions, logs, PCIe driver binds, etcetera), and eventually, you’ll figure it out.
https://github.com/mysteryx93/GPU-Passthrough-with-Optimus-Manager-Guide is linked in one of the issues and specifically concerns your kind of laptop.
I might be able to send over some of my XML to get you started, but I don’t know how helpful that will actually be over the tutorial, as our systems are completely different, and the AMD GPU I use has different bugs/quirks when doing this than Nvidia ones. The truth of the matter on why there’s not really a single-click, easy way to do GPU passthrough is because each system is unique, from the motherboard PCIe implementation to bugs in GPU firmware. That doesn’t mean you shouldn’t try, but it takes a bit of ingenuity.