|
|
Descriptiongpu: fix gpu process crashed on win_blink_rel due to dcheck in CopyTextureCHROMIUM.
When gpu context is lost, CopyTextureCHROMIUMResourceManager can be deleted
without releasing resources like GLES2DecoderImpl.
BUG=438950
Committed: https://crrev.com/4decc8740001718826b165f64428829e4b4abfec
Cr-Commit-Position: refs/heads/master@{#307075}
Patch Set 1 #
Total comments: 1
Patch Set 2 : add comments #
Total comments: 1
Messages
Total messages: 17 (3 generated)
dongseong.hwang@intel.com changed reviewers: + kbr@chromium.org, sievers@chromium.org
@sievers, could you review this P1 bug? GLES2DecoderImpl::Destroy() doesn't release resources when real gl context is lost. It means dtor of CopyTextureCHROMIUMResourceManager can be called without calling CopyTextureCHROMIUMResourceManager::Destroy(). So I remove the invalid DCHECK.
dsinclair@chromium.org changed reviewers: + dsinclair@chromium.org, piman@chromium.org
lgtm
lgtm
https://codereview.chromium.org/780293002/diff/1/gpu/command_buffer/service/g... File gpu/command_buffer/service/gles2_cmd_copy_texture_chromium.cc (left): https://codereview.chromium.org/780293002/diff/1/gpu/command_buffer/service/g... gpu/command_buffer/service/gles2_cmd_copy_texture_chromium.cc:263: DCHECK(!buffer_id_); Please add the comment here from the CL description about why this manager might be deleted without releasing resources. Otherwise it's going to be difficult to reconstruct from the version history why this was removed.
On 2014/12/05 18:21:05, sievers wrote: > lgtm Thank you for review. On 2014/12/05 18:59:28, Ken Russell wrote: > https://codereview.chromium.org/780293002/diff/1/gpu/command_buffer/service/g... > File gpu/command_buffer/service/gles2_cmd_copy_texture_chromium.cc (left): > > https://codereview.chromium.org/780293002/diff/1/gpu/command_buffer/service/g... > gpu/command_buffer/service/gles2_cmd_copy_texture_chromium.cc:263: > DCHECK(!buffer_id_); > Please add the comment here from the CL description about why this manager might > be deleted without releasing resources. Otherwise it's going to be difficult to > reconstruct from the version history why this was removed. Yes, done.
The CQ bit was checked by dongseong.hwang@intel.com
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/780293002/20001
https://codereview.chromium.org/780293002/diff/20001/gpu/command_buffer/servi... File gpu/command_buffer/service/gles2_cmd_copy_texture_chromium.cc (right): https://codereview.chromium.org/780293002/diff/20001/gpu/command_buffer/servi... gpu/command_buffer/service/gles2_cmd_copy_texture_chromium.cc:265: // GLES2DecoderImpl. nit: is there a way to check that the GL resources were cleared if the context was not lost? I wouldn't want a new field introduced that we forgot to clear and cause a leak. Since we don't track GL-level objects, it can be very hard to detect and track down this kind of leak.
On 2014/12/05 20:34:12, piman (Very slow to review) wrote: > https://codereview.chromium.org/780293002/diff/20001/gpu/command_buffer/servi... > File gpu/command_buffer/service/gles2_cmd_copy_texture_chromium.cc (right): > > https://codereview.chromium.org/780293002/diff/20001/gpu/command_buffer/servi... > gpu/command_buffer/service/gles2_cmd_copy_texture_chromium.cc:265: // > GLES2DecoderImpl. > nit: is there a way to check that the GL resources were cleared if the context > was not lost? I wouldn't want a new field introduced that we forgot to clear and > cause a leak. Since we don't track GL-level objects, it can be very hard to > detect and track down this kind of leak. There must be expectations in the decoder unittests for creating and destroying the resources. (Although this kind of testing is really a bit of writing the same code twice in different ways :)
On 2014/12/05 20:38:15, sievers wrote: > On 2014/12/05 20:34:12, piman (Very slow to review) wrote: > > > https://codereview.chromium.org/780293002/diff/20001/gpu/command_buffer/servi... > > File gpu/command_buffer/service/gles2_cmd_copy_texture_chromium.cc (right): > > > > > https://codereview.chromium.org/780293002/diff/20001/gpu/command_buffer/servi... > > gpu/command_buffer/service/gles2_cmd_copy_texture_chromium.cc:265: // > > GLES2DecoderImpl. > > nit: is there a way to check that the GL resources were cleared if the context > > was not lost? I wouldn't want a new field introduced that we forgot to clear > and > > cause a leak. Since we don't track GL-level objects, it can be very hard to > > detect and track down this kind of leak. > > There must be expectations in the decoder unittests for creating and destroying > the resources. > (Although this kind of testing is really a bit of writing the same code twice in > different ways :) Nope, that was removed in https://chromiumcodereview.appspot.com/10450030. (Although the ids, ::kServiceCopyTextureChromium* are left behind.)
On 2014/12/05 20:45:17, sievers wrote: > On 2014/12/05 20:38:15, sievers wrote: > > On 2014/12/05 20:34:12, piman (Very slow to review) wrote: > > > > > > https://codereview.chromium.org/780293002/diff/20001/gpu/command_buffer/servi... > > > File gpu/command_buffer/service/gles2_cmd_copy_texture_chromium.cc (right): > > > > > > > > > https://codereview.chromium.org/780293002/diff/20001/gpu/command_buffer/servi... > > > gpu/command_buffer/service/gles2_cmd_copy_texture_chromium.cc:265: // > > > GLES2DecoderImpl. > > > nit: is there a way to check that the GL resources were cleared if the > context > > > was not lost? I wouldn't want a new field introduced that we forgot to clear > > and > > > cause a leak. Since we don't track GL-level objects, it can be very hard to > > > detect and track down this kind of leak. > > > > There must be expectations in the decoder unittests for creating and > destroying > > the resources. > > (Although this kind of testing is really a bit of writing the same code twice > in > > different ways :) > > Nope, that was removed in https://chromiumcodereview.appspot.com/10450030. > (Although the ids, ::kServiceCopyTextureChromium* are left behind.) Can we just make Destroy(bool have_context) explicit and DCHECK(was_destroyed) in the destructor? Btw, I introduced the same bug in gl_copy_texture_CHROMIUM_unittest.cc which doesn't handle context lost.
On 2014/12/05 20:46:46, sievers wrote: > On 2014/12/05 20:45:17, sievers wrote: > > On 2014/12/05 20:38:15, sievers wrote: > > > On 2014/12/05 20:34:12, piman (Very slow to review) wrote: > > > > > > > > > > https://codereview.chromium.org/780293002/diff/20001/gpu/command_buffer/servi... > > > > File gpu/command_buffer/service/gles2_cmd_copy_texture_chromium.cc > (right): > > > > > > > > > > > > > > https://codereview.chromium.org/780293002/diff/20001/gpu/command_buffer/servi... > > > > gpu/command_buffer/service/gles2_cmd_copy_texture_chromium.cc:265: // > > > > GLES2DecoderImpl. > > > > nit: is there a way to check that the GL resources were cleared if the > > context > > > > was not lost? I wouldn't want a new field introduced that we forgot to > clear > > > and > > > > cause a leak. Since we don't track GL-level objects, it can be very hard > to > > > > detect and track down this kind of leak. > > > > > > There must be expectations in the decoder unittests for creating and > > destroying > > > the resources. > > > (Although this kind of testing is really a bit of writing the same code > twice > > in > > > different ways :) > > > > Nope, that was removed in https://chromiumcodereview.appspot.com/10450030. > > (Although the ids, ::kServiceCopyTextureChromium* are left behind.) > > Can we just make Destroy(bool have_context) explicit and DCHECK(was_destroyed) > in the destructor? > > Btw, I introduced the same bug in gl_copy_texture_CHROMIUM_unittest.cc which > doesn't handle context lost. Err gles2_cmd_clear_framebuffer.cc I meant.
Message was sent while issue was closed.
Committed patchset #2 (id:20001)
Message was sent while issue was closed.
Patchset 2 (id:??) landed as https://crrev.com/4decc8740001718826b165f64428829e4b4abfec Cr-Commit-Position: refs/heads/master@{#307075} |