Serious Canvas2d image draw regression in Chrome 64
Reported by
peter.si...@prezi.com,
Feb 8 2018
|
||||||||||||||
Issue descriptionUserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.140 Safari/537.36 Steps to reproduce the problem: 1. open http://jsfiddle.net/fujwj64k/ 2. click on drawFromAtlas, this performs a set of image draws 3. on Chrome 64 this blocks the browser for 1-2 seconds (!) even on a relatively strong 16GB Macbook with 2GB Geforce 750M, (the image draw API calls themselves take a few millisecs, but there's a blocking busy GPU activity after them according to profiler) 4. this same drawFromAtlas doesn't block on Chrome 66 (and Chrome 63-), just takes a few millisecs until GPU activity yields. About the fiddle: this is an image draw performance test fiddle which generates a set of 2d canvases (with cat images of course), and draws them either directly on a target canvas attached to DOM, or can draw them on larger (atlas) canvases, and draws them to a DOM canvas from these atlases What is the expected behavior? What went wrong? Chrome 64 has a serious Canvas2d image draw regression, which causes a breakdown in graphics intensive applications, for example makes the cloud based presentation product Prezi editor unusable on Chrome with a serious business impact. We have an isolated repro, see the fiddle in the repro section. The issue seems to be fixed on current Canary, but not on current Dev channel (M65). We really hope the issue/fix can be bisected and backported to 64 otherwise we would have to disable Chrome for Prezi users and route them to other browsers for months until M66 rolls out as stable. (which is not really good for us, the users, or Chrome) Thanks in advance! Did this work before? Yes 63 Does this work in other browsers? Yes Chrome version: 64.0.3282.140 Channel: stable OS Version: OS X 10.12.6 Flash Version:
,
Feb 8 2018
I testes in a local build of of Chrome 65 and I can confirm that the regression is caused by: https://chromium-review.googlesource.com/c/chromium/src/+/892082 We can swap that fix for this one in the M65 branch and it will solve both the flickering issue and this perf regression simultaneously: https://chromium-review.googlesource.com/c/chromium/src/+/907668 The same fix swap is also possible for M64.
,
Feb 9 2018
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/245255909f0000029456f338047eebd2eb289deb commit 245255909f0000029456f338047eebd2eb289deb Author: Justin Novosad <junov@chromium.org> Date: Fri Feb 09 15:43:14 2018 Fix canvas flickering properly and remove GPU performance regression This cherry-picks crrev.com/52414e641ddbb11d961cdce88a96c726e419fb09 This reverts commit crrev.com/50866a21df4db7106c54f5879033623fba195c66 This change removes the previous fix for canvas flickering, which introduced performance and GPU memory regressions, and replaces it with a cleaner fix that simply flags the correct GL state invalidations to skia. BUG=805605, 810378 TBR=emircan@chromium.org,xlai@chromium.org Cq-Include-Trybots: master.tryserver.blink:linux_trusty_blink_rel;master.tryserver.chromium.linux:linux_layout_tests_slimming_paint_v2 Change-Id: I2daa1096422a5a8fe1168b4bce495f48e10b37fb Reviewed-on: https://chromium-review.googlesource.com/911608 Reviewed-by: Justin Novosad <junov@chromium.org> Cr-Commit-Position: refs/branch-heads/3325@{#401} Cr-Branched-From: bc084a8b5afa3744a74927344e304c02ae54189f-refs/heads/master@{#530369} [modify] https://crrev.com/245255909f0000029456f338047eebd2eb289deb/content/renderer/media_capture_from_element/canvas_capture_handler.cc [modify] https://crrev.com/245255909f0000029456f338047eebd2eb289deb/third_party/WebKit/Source/platform/graphics/CanvasResourceProvider.cpp
,
Feb 9 2018
The problem is now resolved in Chrome 65. It will get picked up in the next beta release (version > 65.0.3325.60) Not sure whether there is going to be an update to Chrome 64. Just in case, I am flagging this fix for consideration.
,
Feb 9 2018
,
Feb 9 2018
Checked the issue on chrome 64.0.3282.157/CrOS 10176.69.0(Peppy), 65.0.3325.56/10323.21.0(link). The system hangs and crashes when clicking on "drawFromAtlas".
,
Feb 9 2018
@#6: Neither of those versions have the fix from #3
,
Feb 9 2018
How long has this fix been baking in canary and dev? How safe is this fix?
,
Feb 9 2018
Fix landed in ToT yesterday (Feb 8), at commit position 535203 It is in the latest canary (66.0.3344.0), but not yet in dev channel.
,
Feb 9 2018
The fix is very safe since it is simply a cache invalidation.
,
Feb 12 2018
Confirmed with junov@ - it's a very fix safe and this is affecting a small number of websites, but practically making them unusable. Approving merge to M64. Branch:3282
,
Feb 12 2018
Please make sure to create a postmortem for this issue as well.
,
Feb 12 2018
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/cf1008302d19fb33fdaeb1fef85f323edc4723c2 commit cf1008302d19fb33fdaeb1fef85f323edc4723c2 Author: Justin Novosad <junov@chromium.org> Date: Mon Feb 12 20:04:09 2018 Fix canvas flickering properly and remove GPU performance regression This cherry-picks crrev.com/52414e641ddbb11d961cdce88a96c726e419fb09 This reverts commit crrev.com/24f4c0b20d9ebbcd12a527cda8c9b4bd11d2ba9d This change removes the previous fix for canvas flickering, which introduced performance and GPU memory regressions, and replaces it with a cleaner fix that simply flags the correct GL state invalidations to skia. BUG=805605, 810378 TBR=emircan@chromium.org,xlai@chromium.org Cq-Include-Trybots: master.tryserver.chromium.linux:linux_layout_tests_slimming_paint_v2 Change-Id: I9b42d18f215e9edcdd2c24ffa5fb9b39ad4140f6 Reviewed-on: https://chromium-review.googlesource.com/914723 Reviewed-by: Justin Novosad <junov@chromium.org> Cr-Commit-Position: refs/branch-heads/3282@{#669} Cr-Branched-From: 5fdc0fab22ce7efd32532ee989b223fa12f8171e-refs/heads/master@{#520840} [modify] https://crrev.com/cf1008302d19fb33fdaeb1fef85f323edc4723c2/content/renderer/media_capture_from_element/canvas_capture_handler.cc [modify] https://crrev.com/cf1008302d19fb33fdaeb1fef85f323edc4723c2/third_party/WebKit/Source/platform/graphics/CanvasResourceProvider.cpp
,
Feb 12 2018
,
Feb 12 2018
Issue 708154 has been merged into this issue.
,
Feb 13 2018
Verified the fix on latest stable 64.0.3282.167 using Mac 10.13.3, Ubuntu 14.04 and Windows 10. i.e; Now no hang of browser is seen after clicking drawFromAtlas link. Attaching screencast for reference. AS the fix is working as intended adding Verified labels. Thanks!
,
Feb 13 2018
Thanks everyone for the fast response and prompt fix!
,
Feb 13 2018
NOTE: Able to reproduce this issue on 64.0.3282.140 using Mac 10.13., windows 7, Fixed on 64.0.3282.167 Mac 10.13.3, Ubuntu 14.04 and Windows 10.
,
Feb 13 2018
Issue 811002 has been merged into this issue.
,
Feb 13 2018
,
Feb 13 2018
,
Feb 14 2018
Android: Works as per expected behavior that is no graphical corruption or hang is obserevd when clicked on drawFromAtlas. Issue verified on 65.0.3325.74
,
Feb 14 2018
Tested this issue on Windows 10, Mac OS 10.12.6 and Ubuntu 14.04 on the reported version 64.0.3282.140 and latest Chrome Build 65.0.3325.73 by following the below steps. Able to reproduce this issue on the reported version 64.0.3282.140 and the issue is fixed on the latest Chrome 65.0.3325.73. On navigating to the given JSfiddle link and clicking on drawFromAtlas link, cannot observe any hang on the browser. Attached is the screen cast for reference. Hence adding TE verified labels as the fix is working as intended. Thanks..
,
Feb 14 2018
Verified it on chrome 64.0.3282.167/CrOS 10176.72.0(Peppy), 65.0.3325.65/10323.30.0(link).
,
Feb 19 2018
Issue 810081 has been merged into this issue. |
||||||||||||||
►
Sign in to add a comment |
||||||||||||||
Comment 1 by manoranj...@chromium.org
, Feb 8 2018