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

Issue 2613793003: [Command buffer] It is unnecessary to set clear_state_dirty when image content changed (Closed)

Created:
3 years, 11 months ago by yunchao
Modified:
3 years, 10 months ago
CC:
chromium-reviews, piman+watch_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

[Command buffer] It is unnecessary to set clear_state_dirty when image content changed by TexStorage2D, TexImage2D, or CompressedTexImge2D. If the image is cleared to 0 by glColorMask() and glClear() in its callee, the callee should call RestoreClearState by itself. It is uncessary to set clear_state_dirty in the caller(TexStorage2D, TexImage2D, CompressedTexImage2D). BUG=678637 CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_optional_gpu_tests_rel;master.tryserver.chromium.mac:mac_optional_gpu_tests_rel;master.tryserver.chromium.win:win_optional_gpu_tests_rel

Patch Set 1 #

Patch Set 2 : remove #

Unified diffs Side-by-side diffs Delta from patch set Stats (+0 lines, -11 lines) Patch
M gpu/command_buffer/service/gles2_cmd_decoder.cc View 1 3 chunks +0 lines, -11 lines 0 comments Download

Messages

Total messages: 17 (11 generated)
yunchao
PTAL. Thanks!
3 years, 11 months ago (2017-01-05 16:19:55 UTC) #8
Ken Russell (switch to Gerrit)
Yunchao, could you please add a unit test for this change?
3 years, 11 months ago (2017-01-05 16:23:34 UTC) #9
yunchao
On 2017/01/05 16:23:34, Ken Russell wrote: > Yunchao, could you please add a unit test ...
3 years, 11 months ago (2017-01-05 16:26:58 UTC) #12
Ken Russell (switch to Gerrit)
On 2017/01/05 16:26:58, yunchao wrote: > On 2017/01/05 16:23:34, Ken Russell wrote: > > Yunchao, ...
3 years, 11 months ago (2017-01-05 16:29:10 UTC) #13
yunchao
On 2017/01/05 16:29:10, Ken Russell wrote: > On 2017/01/05 16:26:58, yunchao wrote: > > On ...
3 years, 11 months ago (2017-01-05 16:38:55 UTC) #14
Zhenyao Mo
3 years, 11 months ago (2017-01-05 18:24:12 UTC) #17
On 2017/01/05 16:38:55, yunchao wrote:
> On 2017/01/05 16:29:10, Ken Russell wrote:
> > On 2017/01/05 16:26:58, yunchao wrote:
> > > On 2017/01/05 16:23:34, Ken Russell wrote:
> > > > Yunchao, could you please add a unit test for this change?
> > > 
> > > Thanks for your kind reminder, Ken. I know that we should add unittest.
But
> > > seems that it is not possible to add appropirate unittest for code
removal?
> > 
> > I haven't studied this code in detail but think it would be possible. The
unit
> > test would run the appropriate command and make sure that
> > framebuffer_state_.clear_state_dirty was not set to true.
> 
> OK, I will try to add unittest for this. However, we still need to make sure
the
> logic itself is correct. You know, sometimes, unit test is well designed to
pass
>  and prevent regression only. It may not expose the logic error in current
> change.

not lgtm

See my comment in https://bugs.chromium.org/p/chromium/issues/detail?id=678637

Powered by Google App Engine
This is Rietveld 408576698