-
Notifications
You must be signed in to change notification settings - Fork 3k
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
gpui/zed: Allow setting a GPU preference #14738
Conversation
I wonder if a better approach might be to prefer external GPUs, but keep the preference of low‐power GPUs when deciding between built‐in GPUs? That would mean that people using eGPU setups would get the high performance they’ve already opted into by plugging in an external GPU, but Intel MacBook Pros would still get a good experience out of the box, without having to add an additional settings. It would be as simple as changing the sort key to On the other hand, if there are any Intel MacBook Pro users who really wish that the built‐in discrete GPU was being used, a setting would make more sense. |
This adds a new setting: ```jsonc { "gpu": "discrete" // or: "integrated } ``` On macOS, this setting will have an effect when selecting the device with which to render windows. On Linux, it's without an effect.
That's a good idea! And a lot simpler. Do you want to open a PR or should I? |
I don’t mind if you open a PR :) One thing I’m unsure about is how it will behave when an external GPU is unplugged, but presumably any issues there would have already existed in Zed anyway, so it wouldn’t be a regression on the state before my first PR. |
For context, see: - #5124 (comment) - #14738 (comment) Short version: on Intel MacBooks it's better to prefer integrated (`is_low_poer()`) GPUs, except when a user has an eGPU plugged-in, in which case they very likely want to prefer that. Before this change, we'd always prefer the integrated GPU, even if an eGPU was available. Now, with this change, if a user has - eGPU - integrated GPU - discrete GPU We'd first prefer eGPU, then integrated, then discrete.
For context, see: - #5124 (comment) - #14738 (comment) Short version: on Intel MacBooks it's better to prefer integrated (`is_low_poer()`) GPUs, except when a user has an eGPU plugged-in, in which case they very likely want to prefer that. Before this change, we'd always prefer the integrated GPU, even if an eGPU was available. Now, with this change, if a user has - eGPU - integrated GPU - discrete GPU We'd first prefer eGPU, then integrated, then discrete. Release Notes: - Changed preference for GPUs on macOS so that eGPUs are now preferred over integrated ones (and both of which are preferred over discrete GPUs) on Intel Macs.
This adds a new setting:
On macOS, this setting will have an effect when selecting the device with which to render windows.
On Linux, it's without an effect.
See: #5124 (comment)
Release Notes:
{"gpu": "discrete"}
. The default is"integrated"
, which is the lower-power GPU.