-
Notifications
You must be signed in to change notification settings - Fork 969
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DRI_PRIME
is not Respected in NVidia Hybrid Setup
#3464
Comments
DRI_PRIME
is not Respected in NVidia Hybrid Setup
@cwfitzgerald The new title isn't exactly an accurate description of my issue. I have an Intel iGPU and an AMD dGPU, and the dGPU drives the monitor; it's first in the enumeration order and is my preferred default even when |
This sounds like it would have been fixed by #3903. Could you confirm that it was? |
I'm afraid not, since wgpu will no longer select the Vulkan backend for my iGPU even when I use |
#4718 is probably the cause of that, try setting |
Wonderful! Yes, it works as I expect now when no power preference is specified. The iGPU is still selected with |
I'm not sure we have the info to detect this. Do the native APIs have a |
Description
My Linux PC has an integrated GPU and a discrete GPU. The discrete GPU drives the monitor, and the compositor runs on it. If I have Vulkan drivers installed for both and don't set any environment variables,
initialize_adapter_from_env_or_default
selects the integrated GPU.Repro steps
On a device with integrated and discrete GPUs, plug the monitor into the discrete GPU and configure it in your BIOS as the boot GPU, leaving the integrated GPU enabled. Install Vulkan drivers for both GPUs. Run one of the wgpu examples and check which adapter it uses.
Expected vs observed behavior
It selects the integrated GPU, regardless of
DRI_PRIME
. I would expect it to choose the first physical device fromvkEnumeratePhysicalDevices
, which is normally "the one used by Wayland/Xorg or the one connected to a display."I would make the case that this should be the behavior when a low power preference is requested, too. A discrete GPU will probably be powered on anyway if the compositor is using it, and choosing the integrated GPU in this case will cause the framebuffer to be copied to the discrete GPU every frame. I'd be interested to hear other opinions on that, though. (This would mean the integrated GPU would never be selected by default, which is what I would prefer. The only reason I have a Vulkan driver installed for it is so I can test applications on both devices.)
Platform
OS: Arch Linux
wgpu commit: 5b8c55c
Integrated and discrete GPUs both use Mesa drivers.
The text was updated successfully, but these errors were encountered: