Platform/GFX/Device Reset Debugging: Difference between revisions

From MozillaWiki
< Platform‎ | GFX
Jump to navigation Jump to search
m (Improve formatting.)
(→‎Install required 3rd-party components: added installing debug layers)
 
(4 intermediate revisions by the same user not shown)
Line 3: Line 3:
This page will explain how to use the Direct3D 11 Debug Layer to retrieve diagnostic information, warning and error messages coming from Firefox. The idea is that in some cases this may provide some insight as to why device resets are occurring.
This page will explain how to use the Direct3D 11 Debug Layer to retrieve diagnostic information, warning and error messages coming from Firefox. The idea is that in some cases this may provide some insight as to why device resets are occurring.


== Installing required 3rd-party components ==
== Install required 3rd-party components ==


In order to use the Debug Layer the Windows SDK has to be installed on your machine, it can be found [https://developer.microsoft.com/en-US/windows/downloads/windows-10-sdk here].
Install the Windows SDK from [https://developer.microsoft.com/en-US/windows/downloads/windows-10-sdk here].


An effective way of gathering the debug output on your systems is a tool published as part of Microsoft SysInternals called DebugView, it can be found [https://technet.microsoft.com/en-us/sysinternals/debugview.aspx here].
You may need to add debug layers by running this in the command window: Dism /online /add-capability /capabilityname:Tools.Graphics.DirectX[[User:Msreckovic|Milan]] ([[User talk:Msreckovic|talk]]) 10:41, 19 July 2017 (PDT)0.0.1.0
 
Download the DebugView, a tool published as part of Microsoft SysInternals, from [https://technet.microsoft.com/en-us/sysinternals/debugview.aspx here]. Extract DebugView.exe (and dbgview.chm if you want the help file) to a location where you can run it from (desktop, for example.)


== Toggle the Direct3D Debug Layer Pref in Firefox ==
== Toggle the Direct3D Debug Layer Pref in Firefox ==


Go to about:config (in a recent nightly build), search for a preference labeled 'gfx.direct3d11.enable-debug-layer'. After you flip this, a restart is required, and firefox will begin outputting D3D11 diagnostic information to the Windows debug output layer.
In about:config, set the boolean preference 'gfx.direct3d11.enable-debug-layer' to true and restart Firefox. Firefox will now begin outputting D3D11 diagnostic information to the Windows debug output layer.
 
== Gather Logging Info ==
 
Start DebugView, go to 'File->Log As File', and log an unlimited size log to a directory of your choice (this log file can grow somewhat large in size so you may want to keep that in mind).
 
Use Firefox as you normally would. After you experience a Device Reset, stop the logging in DebugView (by simply clicking File->Log As File again).
 
== Submitting the collected information ==


== Gathering Logging Info ==
The collected logs contain debug output from all running applications, and as such may contain sensitive information.


The next step is to startup DebugView, go to 'File->Log As File', and log an unlimited size log to a file of your choice (this log file can grow somewhat large in size so you may want to keep that in mind). Now proceed to use Firefox as you normally would. After you experience a Device Reset, you can stop the logging in DebugView (by simply clicking File->Log As File again), and attach the log to a bug for evaluation by a Firefox graphics engineer. Be aware that these logs contain -all- of your running application's debug output and may contain personally identifiable or privacy sensitive information if any of your applications are doing sloppy logging.
Attach the log file to a [https://bugzilla.mozilla.org/enter_bug.cgi?product=Core&component=Graphics new] or existing https://bugzilla.mozilla.org bug for evaluation by a Firefox graphics engineer. You will want to set the privacy checkbox when adding the attachment to bugzilla - the one that says "Make attachment and comment private (visible only to members of the core-security-release group)".  This will ensure that any private information, if any, is not available to general public.

Latest revision as of 17:41, 19 July 2017

Debugging Device Resets

This page will explain how to use the Direct3D 11 Debug Layer to retrieve diagnostic information, warning and error messages coming from Firefox. The idea is that in some cases this may provide some insight as to why device resets are occurring.

Install required 3rd-party components

Install the Windows SDK from here.

You may need to add debug layers by running this in the command window: Dism /online /add-capability /capabilityname:Tools.Graphics.DirectXMilan (talk) 10:41, 19 July 2017 (PDT)0.0.1.0

Download the DebugView, a tool published as part of Microsoft SysInternals, from here. Extract DebugView.exe (and dbgview.chm if you want the help file) to a location where you can run it from (desktop, for example.)

Toggle the Direct3D Debug Layer Pref in Firefox

In about:config, set the boolean preference 'gfx.direct3d11.enable-debug-layer' to true and restart Firefox. Firefox will now begin outputting D3D11 diagnostic information to the Windows debug output layer.

Gather Logging Info

Start DebugView, go to 'File->Log As File', and log an unlimited size log to a directory of your choice (this log file can grow somewhat large in size so you may want to keep that in mind).

Use Firefox as you normally would. After you experience a Device Reset, stop the logging in DebugView (by simply clicking File->Log As File again).

Submitting the collected information

The collected logs contain debug output from all running applications, and as such may contain sensitive information.

Attach the log file to a new or existing https://bugzilla.mozilla.org bug for evaluation by a Firefox graphics engineer. You will want to set the privacy checkbox when adding the attachment to bugzilla - the one that says "Make attachment and comment private (visible only to members of the core-security-release group)". This will ensure that any private information, if any, is not available to general public.