Last Comment Bug 591057 - Handle multiple GPUs in about:support
: Handle multiple GPUs in about:support
Status: RESOLVED FIXED
:
Product: Core
Classification: Components
Component: Graphics (show other bugs)
: unspecified
: x86 Windows 7
: -- normal with 1 vote (vote)
: mozilla8
Assigned To: Ali Juma [:ajuma]
:
Mentors:
Depends on:
Blocks: about:support++ 628129
  Show dependency treegraph
 
Reported: 2010-08-26 14:41 PDT by Jeff Muizelaar [:jrmuizel]
Modified: 2011-10-07 20:21 PDT (History)
7 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
Identify active GPU in about:support and crash reports (19.66 KB, patch)
2011-07-28 08:29 PDT, Ali Juma [:ajuma]
jmuizelaar: review+
Details | Diff | Splinter Review
Identify active GPU in about:support and crash reports (33.46 KB, patch)
2011-08-09 06:49 PDT, Ali Juma [:ajuma]
jmuizelaar: review+
Details | Diff | Splinter Review
List both GPUs in about:support and crash reports (31.75 KB, patch)
2011-08-15 10:53 PDT, Ali Juma [:ajuma]
jmuizelaar: review+
Details | Diff | Splinter Review

Description Jeff Muizelaar [:jrmuizel] 2010-08-26 14:41:16 PDT
Currently we only show the primary device detected at start up. I'm not sure how this interacts with multiple gpus.
Comment 1 Ali Juma [:ajuma] 2011-07-28 08:29:47 PDT
Created attachment 549122 [details] [diff] [review]
Identify active GPU in about:support and crash reports

This is a revised version of Attachment 544601 [details] [diff] from Bug 628129.

This patch checks the Windows registry for the presence of dual GPUs. If dual GPUs are present:
-D3D9 is used to determine which GPU is active
-both the active and inactive GPUs are listed in about:support and in crash reports

There are no changes to the blacklisting logic. The current objective is to identify dual GPU systems and gather information that will help us decide whether we should later change the blacklisting logic to rely on what D3D9 tells us.
Comment 2 Jeff Muizelaar [:jrmuizel] 2011-08-04 14:39:20 PDT
Comment on attachment 549122 [details] [diff] [review]
Identify active GPU in about:support and crash reports

Yes please.
Comment 3 Ali Juma [:ajuma] 2011-08-09 06:49:36 PDT
Created attachment 551742 [details] [diff] [review]
Identify active GPU in about:support and crash reports

Patch updated to include stubs for GetAdapter*2, GetDriver*2, and GetIsGPU2Active in all non-Windows implementors of GfxInfo.
Comment 4 Benoit Jacob [:bjacob] (mostly away) 2011-08-10 15:55:24 PDT
http://hg.mozilla.org/mozilla-central/rev/02d5f1c5d438
Comment 5 Benoit Jacob [:bjacob] (mostly away) 2011-08-11 11:36:09 PDT
Backed out due to 4% Ts regression :-(

http://hg.mozilla.org/mozilla-central/rev/ffb2a6be641a
Comment 6 Ali Juma [:ajuma] 2011-08-15 07:02:32 PDT
This regression was surprising since the likely cause of it -- the D3D9 code -- should only run on machines where multiple GPUs are detected, but the Talos machines have a single GPU.

It turns out that the Windows registry on the Talos machines has entries for two display devices, even though there is only one GPU actually present (the additional entry is for an Intel 945GM). As a result, the D3D9 code is being run on the Talos machines. I verified that the D3D9 code increases Ts by about 4.1%, accounting for the entire regression. 

Since the display device entries in the registry seem to retain stale information, we need a better way to determine which GPUs are actually present on a machine.
Comment 7 Emanuel Hoogeveen [:ehoogeveen] 2011-08-15 07:11:52 PDT
For Direct3D 9, the following pages seem relevant:
http://msdn.microsoft.com/en-us/library/bb174315.aspx
http://msdn.microsoft.com/en-us/library/bb147355.aspx

For Direct3D 10 (and 11), this page seems relevant:
http://msdn.microsoft.com/en-us/library/ff476877.aspx
Comment 8 Ali Juma [:ajuma] 2011-08-15 10:53:41 PDT
Created attachment 553216 [details] [diff] [review]
List both GPUs in about:support and crash reports

This is the previous patch without any D3D9 code. That is, when the Windows registry lists more than one GPU, both GPUs will be included in about:support and in crash reports. However, no attempt is made to determine which GPU is currently active.

This seems like a reasonable approach to use for now, while we are still investigating better approaches.
Comment 9 Benoit Jacob [:bjacob] (mostly away) 2011-08-15 13:02:39 PDT
http://hg.mozilla.org/mozilla-central/rev/f597467fac5e
Comment 10 Ali Juma [:ajuma] 2011-08-15 13:33:34 PDT
I've filed a follow-up bug (Bug 679110) for improving the way we determine which GPUs are actually present.

Note You need to log in before you can comment on or make changes to this bug.