Last Comment Bug 777700 - Graphics driver crash causes images to stop rendering
: Graphics driver crash causes images to stop rendering
Status: VERIFIED FIXED
:
Product: Core
Classification: Components
Component: Graphics (show other bugs)
: Trunk
: x86_64 Windows 7
: -- normal (vote)
: mozilla17
Assigned To: Bas Schouten (:bas.schouten)
:
Mentors:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2012-07-26 06:46 PDT by Joshua Cranmer [:jcranmer]
Modified: 2012-08-07 05:58 PDT (History)
6 users (show)
ryanvm: in‑testsuite-
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
Part 1: Add functionality to check validity of a source surface (3.48 KB, patch)
2012-07-27 11:16 PDT, Bas Schouten (:bas.schouten)
jmuizelaar: review+
Details | Diff | Splinter Review
Part 2: Only use cached surface when it's valid. (1.34 KB, patch)
2012-07-27 11:17 PDT, Bas Schouten (:bas.schouten)
jmuizelaar: review+
Details | Diff | Splinter Review

Description Joshua Cranmer [:jcranmer] 2012-07-26 06:46:16 PDT
Periodically, my laptop appears to suffer from various graphics driver crashes and restarts. When this happens, on nightly builds, all images (including icons) suddenly disappear. This does not happen on current release version of Firefox (14 IIRC?).
Comment 1 Bas Schouten (:bas.schouten) 2012-07-26 07:13:07 PDT
(In reply to Joshua Cranmer [:jcranmer] from comment #0)
> Periodically, my laptop appears to suffer from various graphics driver
> crashes and restarts. When this happens, on nightly builds, all images
> (including icons) suddenly disappear. This does not happen on current
> release version of Firefox (14 IIRC?).

This could be a symptom of Azure-content. I'll look into this, we'll probably be switching Azure off for 15 so that would fix this problem for you.

On another note though, what's your hardware and driver version, if it crashes that often it should probably be blacklisted for acceleration altogether.
Comment 2 Joshua Cranmer [:jcranmer] 2012-07-26 07:19:13 PDT
From about:support:

Graphics
Adapter Description	NVIDIA Quadro FX 880M
Vendor ID	0x10de
Device ID	0x0a3c
Adapter RAM	1024
Adapter Drivers	nvd3dumx,nvwgf2umx,nvwgf2umx nvd3dum,nvwgf2um,nvwgf2um
Driver Version	8.17.12.5738
Driver Date	6-27-2010
Direct2D Enabled	true
DirectWrite Enabled	true (6.1.7601.17789)
ClearType Parameters	ClearType parameters not found
WebGL Renderer	Google Inc. -- ANGLE (NVIDIA Quadro FX 880M) -- OpenGL ES 2.0 (ANGLE 1.0.0.1041)
GPU Accelerated Windows	1/1 Direct3D 10
AzureBackend	direct2d
Comment 3 Bas Schouten (:bas.schouten) 2012-07-26 07:23:18 PDT
Those drivers are only -just- not blacklisted. In general it would be good if you could upgrade, although the issue should still be fixed. I'm not sure if we should blacklist this card/driver combination.
Comment 4 Joshua Cranmer [:jcranmer] 2012-07-26 07:25:49 PDT
I used to notice a few months ago some fairly frequent crashes (= multiple times per day), but nowadays the driver crashes are relatively rare, maybe once a week?
Comment 5 Joe Drew (not getting mail) 2012-07-26 12:27:08 PDT
A lot of people have reported to me that graphics driver crashes make images disappear with azure content, fwiw.
Comment 6 Bas Schouten (:bas.schouten) 2012-07-26 13:17:41 PDT
That just reaffirms my belief we should switch Azure content off on beta and fix these issues on Aurora (or rather, I will).
Comment 7 Bas Schouten (:bas.schouten) 2012-07-27 11:16:11 PDT
Created attachment 646638 [details] [diff] [review]
Part 1: Add functionality to check validity of a source surface

Since driver crash behaviour is somewhat hard to emulate, it's hard to say for sure, but I suspect I understand the problem. I've created some patches to verify cached source surfaces come from the correct device.
Comment 8 Bas Schouten (:bas.schouten) 2012-07-27 11:17:17 PDT
Created attachment 646639 [details] [diff] [review]
Part 2: Only use cached surface when it's valid.
Comment 9 Jeff Muizelaar [:jrmuizel] 2012-07-27 14:34:35 PDT
Comment on attachment 646638 [details] [diff] [review]
Part 1: Add functionality to check validity of a source surface

Review of attachment 646638 [details] [diff] [review]:
-----------------------------------------------------------------

::: gfx/2d/2D.h
@@ +303,5 @@
>    virtual IntSize GetSize() const = 0;
>    virtual SurfaceFormat GetFormat() const = 0;
>  
> +  /* This returns false if some event has made this source surface invalid for
> +   * usage with current DrawTargets.

Might want to add the example of what happens to D2D here.

::: gfx/2d/SourceSurfaceD2D.h
@@ +41,5 @@
>    friend class DrawTargetD2D;
>  
>    uint32_t GetByteSize() const;
>  
>    RefPtr<ID2D1Bitmap> mBitmap;

Add a comment about why we need to keep a pointer to the device
Comment 10 Jeff Muizelaar [:jrmuizel] 2012-07-27 14:34:42 PDT
Comment on attachment 646639 [details] [diff] [review]
Part 2: Only use cached surface when it's valid.

Review of attachment 646639 [details] [diff] [review]:
-----------------------------------------------------------------

::: gfx/thebes/gfxPlatform.cpp
@@ +20,5 @@
>  #if defined(XP_WIN)
>  #include "gfxWindowsPlatform.h"
>  #include "gfxD2DSurface.h"
> +
> +#include <d3d10_1.h>

Do we need this?

@@ +506,5 @@
> +    SourceSurface *surf = static_cast<SourceSurface*>(userData);
> +
> +    if (surf->IsValid()) {
> +      return surf;
> +    }

Will this surface be removed below?
Comment 14 Joshua Cranmer [:jcranmer] 2012-08-07 05:58:52 PDT
Images remained around after my latest driver cache.

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