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

Issue 2547013002: Add Intel macOS workaround for WebGL2 canvas_sub_rectangle tests (Closed)

Created:
4 years ago by jchen10
Modified:
3 years, 3 months ago
CC:
chromium-reviews, f(malita), krit, drott+blinkwatch_chromium.org, ajuma+watch-canvas_chromium.org, dshwang, jam, jbroman, Justin Novosad, blink-reviews-platform-graphics_chromium.org, Rik, darin-cc_chromium.org, pdr+graphicswatchlist_chromium.org, blink-reviews, piman+watch_chromium.org, danakj+watch_chromium.org, ajuma+watch_chromium.org, Stephen Chennney, rwlbuis
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Add Intel macOS workaround for WebGL2 canvas_sub_rectangle tests Reading pixels back from a texture based 2D canvas is flaky with Mac Intel driver. This workarounds it by doing a redundant texture copy before reading. The issue happens using TexImage2D and TexSubImage2D in turn to source from a GPU-based 2D canvas. Currently TexImage2D may be hardware-accelerated via GPU texture copying, whereas TexSubImage2D has to do software read-back as blink has no knowledge of destination texture's internal format. The cases can pass if merely testing either, but fail testing both with the software and hardware copy mixed. BUG=665656 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;master.tryserver.chromium.android:android_optional_gpu_tests_rel

Patch Set 1 #

Patch Set 2 : Add AccelerationHint #

Patch Set 3 : Workaournd for Canvas2D pixel readback #

Patch Set 4 : add comments #

Total comments: 4
Unified diffs Side-by-side diffs Delta from patch set Stats (+64 lines, -55 lines) Patch
M content/browser/gpu/gpu_data_manager_impl_private.cc View 1 2 1 chunk +2 lines, -0 lines 0 comments Download
M content/public/common/common_param_traits_macros.h View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M content/public/common/web_preferences.h View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M content/public/common/web_preferences.cc View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M content/renderer/render_view_impl.cc View 1 2 1 chunk +3 lines, -0 lines 0 comments Download
M content/test/gpu/gpu_tests/webgl2_conformance_expectations.py View 1 2 1 chunk +0 lines, -40 lines 0 comments Download
M gpu/config/gpu_driver_bug_list_json.cc View 1 2 2 chunks +13 lines, -1 line 0 comments Download
M gpu/config/gpu_driver_bug_workaround_type.h View 1 2 1 chunk +2 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/frame/Settings.in View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M third_party/WebKit/Source/modules/webgl/WebGLRenderingContextBase.cpp View 1 2 3 chunks +14 lines, -8 lines 0 comments Download
M third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp View 1 2 3 3 chunks +18 lines, -6 lines 4 comments Download
M third_party/WebKit/Source/platform/graphics/GraphicsTypes.h View 1 2 3 1 chunk +2 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/web/WebSettingsImpl.h View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M third_party/WebKit/Source/web/WebSettingsImpl.cpp View 1 2 1 chunk +4 lines, -0 lines 0 comments Download
M third_party/WebKit/public/web/WebSettings.h View 1 2 1 chunk +1 line, -0 lines 0 comments Download

Messages

Total messages: 52 (42 generated)
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2547013002/1
4 years ago (2016-12-02 13:14:18 UTC) #3
commit-bot: I haz the power
No L-G-T-M from a valid reviewer yet. CQ run can only be started by full ...
4 years ago (2016-12-02 13:14:19 UTC) #5
jchen10
Please have a review first!
4 years ago (2016-12-05 01:09:29 UTC) #37
qiankun
Looks good to me. https://codereview.chromium.org/2547013002/diff/60001/third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp File third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp (right): https://codereview.chromium.org/2547013002/diff/60001/third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp#newcode1124 third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp:1124: // snapshot, on Intel MacOS ...
4 years ago (2016-12-05 08:25:31 UTC) #45
bsalomon
https://codereview.chromium.org/2547013002/diff/60001/third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp File third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp (right): https://codereview.chromium.org/2547013002/diff/60001/third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp#newcode1124 third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp:1124: // snapshot, on Intel MacOS platform(crbug.com/665656). On 2016/12/05 08:25:31, ...
4 years ago (2016-12-05 14:12:41 UTC) #46
Zhenyao Mo
+junov for insights https://codereview.chromium.org/2547013002/diff/60001/third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp File third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp (right): https://codereview.chromium.org/2547013002/diff/60001/third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp#newcode1126 third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp:1126: m_surface->makeSurface(m_surface->getCanvas()->imageInfo()).reset(); This seems a big perf ...
4 years ago (2016-12-05 18:13:36 UTC) #48
Kai Ninomiya
On 2016/12/05 18:13:36, Zhenyao Mo wrote: > +junov for insights > > https://codereview.chromium.org/2547013002/diff/60001/third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp > File ...
4 years ago (2016-12-05 18:41:32 UTC) #49
Justin Novosad
https://codereview.chromium.org/2547013002/diff/60001/third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp File third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp (right): https://codereview.chromium.org/2547013002/diff/60001/third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp#newcode1125 third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp:1125: if (hint == PreferAccelerationWithExtraSurfaceCopy) This is a misuse of ...
4 years ago (2016-12-05 20:54:02 UTC) #50
Ken Russell (switch to Gerrit)
Note also from talking with that the reason we are going down the readback path ...
4 years ago (2016-12-06 00:01:55 UTC) #51
Kai Ninomiya
4 years ago (2016-12-06 06:57:06 UTC) #52
On 2016/12/06 00:01:55, Ken Russell wrote:
> Note also from talking with that the reason we are going down the readback
path
> in the first place is that CopySubTextureCHROMIUM doesn't yet have the
necessary
> validation to reject illegal calls when the internal format differs from the
> texture's allocated internal format:
>
https://cs.chromium.org/chromium/src/third_party/WebKit/Source/modules/webgl/...
> .
> 
> I agree with zmo's concern that this is a potentially very expensive
workaround.
> I think that we should do some more work to identify what might be going wrong
> in the driver so that we can create a reduced test case, and possibly a more
> targeted workaround.

See https://crbug.com/665656#c22 for update on my investigation

Powered by Google App Engine
This is Rietveld 408576698