WebGL context destruction hangs on Droid

RESOLVED FIXED

Status

()

RESOLVED FIXED
8 years ago
8 years ago

People

(Reporter: jrmuizel, Assigned: jrmuizel)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(2 attachments)

Comment hidden (empty)
(Assignee)

Updated

8 years ago
Assignee: nobody → jmuizelaar
(Assignee)

Comment 1

8 years ago
We hang on the call to glDeleteFramebuffers
(Assignee)

Comment 2

8 years ago
Seems to be because we're calling glDeleteFramebuffers on framebuffers we never created.
exciting -- where do we do this call?  mOffscreenFBO (if that's the FBO we're talking about) is initialized to 0, and deleting it is supposed to be silently ignored.
(Assignee)

Comment 4

8 years ago
calling glDeleteFramebuffers with 0 as the number seems to cause hangs on the Droid. I think the best thing to do is just check before we call glDeleteFramebuffers.
Ok, but please find a way to report this bug to Motorola or PowerVR -- this basically means we'll have to either protect every other delete function as well or we'll have to disable things like WebGL.  disabling WebGL on the Droid is no big loss though
(Assignee)

Comment 6

8 years ago
Created attachment 501448 [details] [diff] [review]
Share the gl wrappers in release/debug versions

This makes it easier to add code for ignoring certain calls etc.
Attachment #501448 - Flags: review?(vladimir)
Comment on attachment 501448 [details] [diff] [review]
Share the gl wrappers in release/debug versions

Looks fine, but:

>+#define TRACKING_CONTEXT(a) TrackingContext()->a
>+#else
>+#define TRACKING_CONTEXT(a)

make this "do { } while (0)", otherwise we have dangling ; 's in the code.
Attachment #501448 - Flags: review?(vladimir) → review+
(Assignee)

Comment 8

8 years ago
Created attachment 501503 [details] [diff] [review]
Avoid glDeleteFramebuffers(1, &0);

This only handles the case where n == 1, I'm not sure if that's ok or not.
Attachment #501503 - Flags: review?(vladimir)
Comment on attachment 501503 [details] [diff] [review]
Avoid glDeleteFramebuffers(1, &0);

it's probably ok for this particular case since we know how it's called
Attachment #501503 - Flags: review?(vladimir) → review+
(Assignee)

Comment 10

8 years ago
http://hg.mozilla.org/mozilla-central/rev/78e5ed32f8f5
http://hg.mozilla.org/mozilla-central/rev/57103cddaf37
Status: NEW → RESOLVED
Last Resolved: 8 years ago
Resolution: --- → FIXED
Hmm we had similar problem on Maemo SGX... but that was fixed in maemo6 SDK.
https://bugzilla.mozilla.org/show_bug.cgi?id=598970#c0
You need to log in before you can comment on or make changes to this bug.