Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.
Sign upadd device_type inference to gl backend #2595
Conversation
This comment has been minimized.
This comment has been minimized.
|
Maybe this whole idea is no good. Intel has discrete cards coming: Should we always say Other? Should we add an Unknown to the Device_Type enum? This would break from the Vulkan API though. |
This comment has been minimized.
This comment has been minimized.
|
Note that AMD also has APUs, which are integrated... I wonder we can do a more precise matching of the adapter name to figure this out. As for the current PR, I don't feel strongly either way. Anyone got a strong opinion here? |
This comment has been minimized.
This comment has been minimized.
|
Not really, I'd slightly prefer a stronger heuristic than vendor. |
This comment has been minimized.
This comment has been minimized.
|
I'm going to do some research on vendor/version/renderer strings and see if we can do better. I've got quite a few computers here to survey. |
This comment has been minimized.
This comment has been minimized.
|
I've got a simple command line program that will print renderer vender and version: I've started compiling results for computers I have access to: if any of you want to add to it or pass this around please do |
This comment has been minimized.
This comment has been minimized.
|
Could also use |
This comment has been minimized.
This comment has been minimized.
|
I figured something like that would exist already |
This comment has been minimized.
This comment has been minimized.
|
if anyone has an "IGP" or "nForce" nvidia card to run glxinfo on I'd like to see the output. the opengl database doesn't have any examples. |
kvark
reviewed
Jan 24, 2019
| let renderer_lower = renderer.to_lowercase(); | ||
| let strings_that_imply_integrated = [ | ||
| " xpress", // space here is on purpose so we don't match express | ||
| "radeon hd 4200", |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
|
oh, ok |
bot
added a commit
that referenced
this pull request
Jan 24, 2019
This comment has been minimized.
This comment has been minimized.
Build succeeded |
jackmott commentedJan 23, 2019
•
edited
A first pass at inferring the device type. If we see "intel" in the device string we can be confident that it is an integratedgpu. If we see "nvidia", "ati", or "amd" it is either going to be discrete or have performance much better than the intel integrated gpu. Otherwise we set device_type to Other since we really have no idea.
Fixes #2593
PR checklist:
makesucceeds (on *nix)make reftestssucceedsrustfmtrun on changed code