Closed Bug 739604 Opened 8 years ago Closed 8 years ago

Crash in ThebesLayerOGL when using MOZ_DUMP_PAINT_LIST

Categories

(Core :: Graphics, defect, critical)

ARM
Android
defect
Not set
critical

Tracking

()

RESOLVED FIXED
mozilla14
Tracking Status
blocking-fennec1.0 --- -

People

(Reporter: cwiiis, Assigned: cwiiis)

Details

(Keywords: crash, Whiteboard: [native-crash])

Attachments

(3 files, 1 obsolete file)

If you enable MOZ_DUMP_PAINT_LIST when using tiles and GL layers, you'll almost certainly get a crash due to uninitialised memory access. This is caused by using TextureImage calls before calling BeginIteration (meaning it may be in an inconsistent state).
erk, so fixing that issue unfortunately just shows it crashing later down the line :( Trying to debug, but it's not giving me a stack...
This restores the behaviour of TiledTextureImage::NextTile to before the patches in bug 732917. This fixes/avoids (at least) one of the crashes, I'm not sure what the cause of the other is yet.
Attachment #609741 - Flags: review?(ajuma)
Comment on attachment 609741 [details] [diff] [review]
Restore old TiledTextureImage::NextTile behaviour

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

::: gfx/gl/GLContext.cpp
@@ +1084,5 @@
> +        mCurrentImage++;
> +    else
> +        return false;
> +
> +    return continueIteration;

It's cleaner to go back to the way it was before:

if (mCurrentImage + 1 < mImages.Length()) {
    mCurrentImage++;
    return continueIteration;
}
return false;
Attachment #609741 - Flags: review?(ajuma) → review+
Severity: normal → critical
Keywords: crash
Whiteboard: [native-crash]
Updated as suggested, and reset mCurrentImage when resizing - carrying over r+.
Attachment #609741 - Attachment is obsolete: true
Attachment #610098 - Flags: review+
This fixes the next crash I was seeing, where gfxUtils::sDumpPaintFile was NULL, but fprintf was being called using it as a parameter.
Attachment #610099 - Flags: review?(matt.woodrow)
MOZ_DUMP_PAINT_LIST is still not useful on mobile anymore because it enables read-back of (almost) every texture (which causes every composite to take in the region of 800-1500ms, instead of the usual 10-40ms) - This read-back also doesn't work correctly with tiled texture-images anyway, so I'll write a patch to separate it into a different option.
Attachment #610099 - Flags: review?(matt.woodrow) → review+
Attachment #610119 - Flags: review?(matt.woodrow) → review+
blocking-fennec1.0: ? → -
You need to log in before you can comment on or make changes to this bug.