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

Issue 221433004: gpu: Bind dummy GL API when no context is current (Closed)

Created:
6 years, 8 months ago by no sievers
Modified:
6 years, 8 months ago
Reviewers:
piman
CC:
chromium-reviews, rjkroege, ozone-reviews_chromium.org, jam, darin-cc_chromium.org, kalyank, piman+watch_chromium.org
Visibility:
Public.

Description

gpu: Bind dummy GL API when no context is current Also make platform behavior consistent in always releasing any previously current context when MakeCurrent() fails. This catches GL call sites with no context current. It also avoids problems with GL implementations potentially not liking this (and crashing) or even us ending up calling into the wrong context (for example accidentally deleting a resource in the wrong context). BUG=355275 R=piman@chromium.org Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=261153

Patch Set 1 #

Patch Set 2 : #

Total comments: 10

Patch Set 3 : always release any context on failure #

Patch Set 4 : fix two gpu unittests #

Unified diffs Side-by-side diffs Delta from patch set Stats (+135 lines, -31 lines) Patch
M content/common/gpu/texture_image_transport_surface.cc View 1 2 chunks +13 lines, -7 lines 0 comments Download
M gpu/command_buffer/service/gles2_cmd_decoder_unittest.cc View 1 2 3 2 chunks +10 lines, -0 lines 0 comments Download
M ui/gl/generate_bindings.py View 4 chunks +42 lines, -12 lines 0 comments Download
M ui/gl/gl_context.h View 1 2 1 chunk +12 lines, -0 lines 0 comments Download
M ui/gl/gl_context.cc View 1 2 2 chunks +14 lines, -0 lines 0 comments Download
M ui/gl/gl_context_cgl.cc View 1 2 3 chunks +2 lines, -1 line 0 comments Download
M ui/gl/gl_context_egl.cc View 1 2 3 chunks +2 lines, -1 line 0 comments Download
M ui/gl/gl_context_glx.cc View 1 2 2 chunks +2 lines, -2 lines 0 comments Download
M ui/gl/gl_context_nsview.mm View 1 2 3 chunks +2 lines, -1 line 0 comments Download
M ui/gl/gl_context_osmesa.cc View 1 2 4 chunks +3 lines, -1 line 0 comments Download
M ui/gl/gl_context_wgl.cc View 1 2 3 chunks +2 lines, -1 line 0 comments Download
M ui/gl/gl_gl_api_implementation.h View 5 chunks +17 lines, -5 lines 0 comments Download
M ui/gl/gl_gl_api_implementation.cc View 4 chunks +14 lines, -0 lines 0 comments Download

Messages

Total messages: 19 (0 generated)
no sievers
ptal. Quite possible that the IOSurface image transport code also tries to make GL calls ...
6 years, 8 months ago (2014-04-01 22:50:00 UTC) #1
no sievers
https://codereview.chromium.org/221433004/diff/20001/ui/gl/gl_context_egl.cc File ui/gl/gl_context_egl.cc (right): https://codereview.chromium.org/221433004/diff/20001/ui/gl/gl_context_egl.cc#newcode124 ui/gl/gl_context_egl.cc:124: if (!surface->OnMakeCurrent(this)) { I guess you could argue whether ...
6 years, 8 months ago (2014-04-01 22:51:32 UTC) #2
piman
lgtm https://codereview.chromium.org/221433004/diff/20001/content/common/gpu/texture_image_transport_surface.cc File content/common/gpu/texture_image_transport_surface.cc (right): https://codereview.chromium.org/221433004/diff/20001/content/common/gpu/texture_image_transport_surface.cc#newcode185 content/common/gpu/texture_image_transport_surface.cc:185: } else { It's not specific to this ...
6 years, 8 months ago (2014-04-01 23:00:02 UTC) #3
no sievers
https://codereview.chromium.org/221433004/diff/20001/content/common/gpu/texture_image_transport_surface.cc File content/common/gpu/texture_image_transport_surface.cc (right): https://codereview.chromium.org/221433004/diff/20001/content/common/gpu/texture_image_transport_surface.cc#newcode185 content/common/gpu/texture_image_transport_surface.cc:185: } else { On 2014/04/01 23:00:02, piman wrote: > ...
6 years, 8 months ago (2014-04-01 23:39:37 UTC) #4
no sievers
https://codereview.chromium.org/221433004/diff/20001/ui/gl/gl_context_egl.cc File ui/gl/gl_context_egl.cc (right): https://codereview.chromium.org/221433004/diff/20001/ui/gl/gl_context_egl.cc#newcode124 ui/gl/gl_context_egl.cc:124: if (!surface->OnMakeCurrent(this)) { On 2014/04/01 23:39:37, sievers wrote: > ...
6 years, 8 months ago (2014-04-01 23:47:23 UTC) #5
piman
https://codereview.chromium.org/221433004/diff/20001/content/common/gpu/texture_image_transport_surface.cc File content/common/gpu/texture_image_transport_surface.cc (right): https://codereview.chromium.org/221433004/diff/20001/content/common/gpu/texture_image_transport_surface.cc#newcode185 content/common/gpu/texture_image_transport_surface.cc:185: } else { On 2014/04/01 23:39:37, sievers wrote: > ...
6 years, 8 months ago (2014-04-01 23:50:58 UTC) #6
no sievers
https://codereview.chromium.org/221433004/diff/20001/ui/gl/gl_context_egl.cc File ui/gl/gl_context_egl.cc (right): https://codereview.chromium.org/221433004/diff/20001/ui/gl/gl_context_egl.cc#newcode124 ui/gl/gl_context_egl.cc:124: if (!surface->OnMakeCurrent(this)) { On 2014/04/01 23:47:23, sievers wrote: > ...
6 years, 8 months ago (2014-04-01 23:51:55 UTC) #7
piman
On Tue, Apr 1, 2014 at 4:51 PM, <sievers@chromium.org> wrote: > > https://codereview.chromium.org/221433004/diff/20001/ui/ > gl/gl_context_egl.cc ...
6 years, 8 months ago (2014-04-01 23:56:19 UTC) #8
piman
On Tue, Apr 1, 2014 at 4:51 PM, <sievers@chromium.org> wrote: > > https://codereview.chromium.org/221433004/diff/20001/ui/ > gl/gl_context_egl.cc ...
6 years, 8 months ago (2014-04-01 23:56:20 UTC) #9
piman
On Tue, Apr 1, 2014 at 4:51 PM, <sievers@chromium.org> wrote: > > https://codereview.chromium.org/221433004/diff/20001/ui/ > gl/gl_context_egl.cc ...
6 years, 8 months ago (2014-04-01 23:59:31 UTC) #10
no sievers
Updated.
6 years, 8 months ago (2014-04-02 00:39:52 UTC) #11
piman
lgtm
6 years, 8 months ago (2014-04-02 00:54:35 UTC) #12
no sievers
The CQ bit was checked by sievers@chromium.org
6 years, 8 months ago (2014-04-02 18:00:52 UTC) #13
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/sievers@chromium.org/221433004/80001
6 years, 8 months ago (2014-04-02 18:02:06 UTC) #14
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 8 months ago (2014-04-02 18:27:02 UTC) #15
commit-bot: I haz the power
Retried try job too often on chromium_presubmit for step(s) presubmit http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=chromium_presubmit&number=59105
6 years, 8 months ago (2014-04-02 18:27:03 UTC) #16
no sievers
Committed patchset #4 manually as r261153 (presubmit successful).
6 years, 8 months ago (2014-04-02 18:37:17 UTC) #17
bungeman-skia
On 2014/04/02 18:37:17, sievers wrote: > Committed patchset #4 manually as r261153 (presubmit successful). It ...
6 years, 8 months ago (2014-04-02 19:33:50 UTC) #18
no sievers
6 years, 8 months ago (2014-04-02 19:39:28 UTC) #19
Message was sent while issue was closed.
On 2014/04/02 19:33:50, bungeman1 wrote:
> On 2014/04/02 18:37:17, sievers wrote:
> > Committed patchset #4 manually as r261153 (presubmit successful).
> 
> It looks like this might require a suppression for the new static
> g_no_context_gl? See
>
http://build.chromium.org/p/chromium.memory/buildstatus?builder=Linux%20ASan%...

This should fix it: https://codereview.chromium.org/220913004/

Powered by Google App Engine
This is Rietveld 408576698