Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(475)

Issue 1153233005: Mark WebGLRenderingContext as having lost context upon init failure. (Closed)

Created:
5 years, 6 months ago by sof
Modified:
5 years, 6 months ago
CC:
blink-reviews, dshwang, blink-reviews-html_chromium.org, dglazkov+blink, Rik, Justin Novosad
Base URL:
https://chromium.googlesource.com/chromium/blink.git@master
Target Ref:
refs/heads/master
Project:
blink
Visibility:
Public.

Description

Mark WebGLRenderingContext as having lost context upon init failure. r196077 added a good test verifying the handling of attempted WebGL context creation when that fails to create an underlying drawing buffer. This exposed an Oilpan-specific lifetime issue for the WebGLRenderingContext object that fails to properly initialize. With Oilpan, that garbage collected & partially initialized object will not be synchronously deleted, but be finalized instead when the next GC strikes. The WebGLRenderingContext object is an ActiveDOMObject attached to its execution context, so should it be stopped before that GC strikes, it will be forcibly removed from its (graphics system) context as part of stopping. The partially constructed object is not prepared for that, with failing consequences. To avoid, if the creation of a drawing buffer fails, we explicitly mark the object as having lost its context. R=bajones,kbr,haraken BUG=474665 Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=196188

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+3 lines, -1 line) Patch
M Source/core/html/canvas/WebGLRenderingContextBase.cpp View 1 chunk +3 lines, -1 line 0 comments Download

Messages

Total messages: 10 (2 generated)
sof
please take a look. Takes care of the Oilpan webgl failures https://storage.googleapis.com/chromium-layout-test-archives/WebKit_Linux_Oilpan__dbg_/1360/layout-test-results/results.html
5 years, 6 months ago (2015-05-29 16:21:13 UTC) #2
bajones
Good catch, thanks for the fix! LGTM
5 years, 6 months ago (2015-05-29 18:16:43 UTC) #3
sof
On 2015/05/29 18:16:43, bajones wrote: > Good catch, thanks for the fix! LGTM Ditto for ...
5 years, 6 months ago (2015-05-29 18:30:19 UTC) #4
Ken Russell (switch to Gerrit)
Nice. Subtle issue. I wonder if there are going to be more when we turn ...
5 years, 6 months ago (2015-05-29 22:52:25 UTC) #5
haraken
LGTM. On 2015/05/29 22:52:25, Ken Russell wrote: > Nice. Subtle issue. I wonder if there ...
5 years, 6 months ago (2015-05-30 00:29:30 UTC) #6
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1153233005/1
5 years, 6 months ago (2015-05-30 05:48:28 UTC) #8
commit-bot: I haz the power
Committed patchset #1 (id:1) as https://src.chromium.org/viewvc/blink?view=rev&revision=196188
5 years, 6 months ago (2015-05-30 05:51:36 UTC) #9
sof
5 years, 6 months ago (2015-05-30 06:26:34 UTC) #10
Message was sent while issue was closed.
On 2015/05/29 22:52:25, Ken Russell wrote:
> Nice. Subtle issue. I wonder if there are going to be more when we turn on
> Oilpan for WebGL. LGTM

It would be prudent to assume so, test coverage (which is excellent for WebGL)
can only get you so far. We're fuzzing Oilpan builds also, but should probably
do more of that.

Powered by Google App Engine
This is Rietveld 408576698