Issue metadata
Sign in to add a comment
|
Inverted WebGL canvas on Canary Windows
Reported by
alecazam...@gmail.com,
Aug 16 2016
|
||||||||||||||||||||||
Issue descriptionUserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/52.0.2743.116 Safari/537.36 Example URL: The editor on figma.com, need account access. Steps to reproduce the problem: 1. Create a new file in the figma.com editor 2. Note that the canvas, interactions, rulers, etc inverted. It looks like an origin flip issue in ANGLE. I did not try the GL backend for Canary, but I did try DX9 and DX11 and they both exhibit the problem in Canary. What is the expected behavior? The WebGL canvas should not be inverted. What went wrong? We render the canvas upside down, and then flip it at the last minute to copy it to the backbuffer. This inversion works on OSX, and on Windows Chrome mainline. It does not work on Windows Chrome Canary. Ken Russell has an account to login to figma to see this issue. I don't have a reduced test case to try. Contact me if you need an account to access Figma. Does it occur on multiple sites: N/A Is it a problem with a plugin? No Did this work before? Yes It works on Chrome mainline now, and on OSX Does this work in other browsers? Yes Chrome version: 52.0.2743.116 Channel: canary OS Version: WIndows 10 Flash Version: Shockwave Flash 22.0 r0
,
Aug 17 2016
This is 100% reproducible. A bisect reveals: You are probably looking for a change made after 406970 (known good), but no later than 407004 (first known bad). CHANGELOG URL: https://chromium.googlesource.com/chromium/src/+log/bec4caf4bf87bdc03f93e5e27c8ab7c14370df8b..79f7b784a97cbb22f11064a05b621b0def87eab3 This changelog is unfortunately quite large. It contains an ANGLE roll: https://chromium.googlesource.com/chromium/src/+/206bdb9446b8cd6493c0496ee0f86719e1486c8b which contains these changes: https://chromium.googlesource.com/angle/angle.git/+log/1be913c..7da9850 Based on feedback from the submitter that some of his shaders using the comma operator were recently affected, I wonder whether Figma is using this GLSL feature excessively and whether the following change affected it: https://chromium.googlesource.com/angle/angle.git/+/e1d199bb9bfcf4d377608a52d5c0889be99724f9 Submitter, you mention that Figma renders the canvas upside down and flips it at the last minute. How exactly is that flip performed? Marking ReleaseBlock-Stable for M-54. M-53 (beta) is fortunately unaffected.
,
Aug 17 2016
It doesn't appear to be: https://chromium.googlesource.com/angle/angle.git/+/e1d199bb9bfcf4d377608a52d5c0889be99724f9 I reverted it locally with no effect.
,
Aug 17 2016
Unfortunately it's not easy to tell whether the ANGLE roll contained the regression or the other Chromium changes in the changelist -- ANGLE can't be rolled back to 1be913c in top-of-tree Chromium apparently because of GN issues.
,
Aug 17 2016
I can take a look at the ANGLE stuff tomorrow Ken, and try to determine if it's related. The best way is to use dropped DLLs in Canary, FYI. We have a script that helps with that, but I'll be happy to help.
,
Aug 17 2016
We just use an inverted full screen quad and shader. The uv are inverted in v(y-axis) so they go 1 to 0. These shaders have gone through a mini fire which comma separates the lines.
,
Aug 17 2016
,
Aug 17 2016
I've bisected this to 7da9850643f55335 by Olli: Cover vector dynamic indexing case in SplitSequenceOperator https://chromium.googlesource.com/angle/angle.git/+/7da9850643f55335a13a4663d226c73d0ac4d3b1 I'll try reverting this in https://chromium-review.googlesource.com/#/c/371643/ but I honestly don't remember what tests this fixed when it landed. Olli can you help diagnose what's going on here?
,
Aug 17 2016
By the, Alec, if you ever use the sequence operator (,) you could try removing this from your shaders to see if that can work around the problem for now.
,
Aug 17 2016
I made my void function return a bool. Didn't want to rewrite the minifier.
,
Aug 17 2016
Thanks Jamie for tracking that down. I thought I reverted the entire use of the SplitSequenceOperator locally by commenting out its application, but probably did something wrong.
,
Aug 17 2016
,
Aug 17 2016
Jamie, let me assign this to you since you're handling the revert. I've reopened the ANGLE bug and blocked it on this one. We'll close this once the revert goes through and expect that the re-land will fix the problem and include a new test.
,
Aug 17 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/ff055014a801b57be9b10714d290321b06259f85 commit ff055014a801b57be9b10714d290321b06259f85 Author: jmadill <jmadill@chromium.org> Date: Wed Aug 17 17:15:24 2016 WebGL: Re-add dynamic indexing test suppression. An ANGLE revert requires this test to be expected to fail. BUG= 638313 TBR=kbr@chromium.org 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 NOTRY=true Review-Url: https://codereview.chromium.org/2249823004 Cr-Commit-Position: refs/heads/master@{#412570} [modify] https://crrev.com/ff055014a801b57be9b10714d290321b06259f85/content/test/gpu/gpu_tests/webgl2_conformance_expectations.py
,
Aug 19 2016
I'll diagnose what's going on here. Had some problems with getting a working Chromium build to test with, but seems like I can make progress now.
,
Aug 20 2016
Thanks very much Olli. Please reach out to the submitter if necessary to figure out what's being mis-handled in the shader. Let's add a WebGL conformance test for this.
,
Aug 20 2016
Downgrading to P2 since the revert has taken effect already. We may want to close this as fixed and open a new bug to track the re-land, since this one was M-54, ReleaseBlock-Stable -- and I think for tracking purposes it should stay that way.
,
Aug 24 2016
oetuaho@: Any update on this.
,
Aug 25 2016
Alec, Ken, Olli: It looks as though it wasn't as nice as a single revert. Better testing shows that I need to revert three CLs to get this demo working again. Alec, can you possibly look at things on your end to see if the minification script possibly makes a statement where there's a void returning function in a sequence? Like you hinted in comment #10, if you can workaround that by making them return something, that would be good. Olli or Ken, do you recall the details of the comma operator with void? Should I revert this stack of CLs, or is this a problematic case of existing content being broken by a spec update? See revert stack here: https://chromium-review.googlesource.com/376121 https://chromium-review.googlesource.com/376122 https://chromium-review.googlesource.com/376123 https://chromium-review.googlesource.com/376124
,
Aug 25 2016
The comma operator isn't allowed to be used with a void return value. Jamie, Olli, I'm not sure that reverting Olli's entire stack of patches is the best thing to do here. His patches make certain complex WebGL conformance tests pass with ANGLE's HLSL backend. I think the first thing to do is un-revert Olli's patch which clearly didn't have an effect on Figma's application. The next thing to do is work with Figma to have them confirm that it's a void return value in a sequence operator that's breaking their shader, and then have them work around that.
,
Aug 26 2016
I can try that. Will get back to you. The fixes I did were for WebGL 2. The shaders that I had didn't compile under WebGL 2. The WebGL 1 shaders all passed, but I'll try this.
,
Aug 26 2016
Finally got around to fixing this, sorry about the delays. This turned out to be a logic error inside the SplitSequenceOperator AST traversal step. It behaved incorrectly when there was a sequence operator nested inside another. ANGLE somewhat unexpectedly generates nested sequence operators in the AST when there is a sequence operator with more than two operands. I've uploaded an ANGLE patch for review here: https://chromium-review.googlesource.com/#/c/376678/ I'll also put together a WebGL conformance test.
,
Aug 26 2016
So I updated our shaders to not have void returns, and the shaders still compile fine in WebGL1 (DX9 and DX11), but the canvas is still inverted. Hopefully the patch will correct the inversion, but we'll update the shaders regardless for our minifier. Some good news is that enabling WebGL 2 no longer breaks our WebGL 1 app when enabled, but we had a user report the breakage. I'll tell them to update Canary.
,
Aug 26 2016
We do still have the DX9 leftover renders, but turning on the Chrome WebGL2 flag used to leave our canvas as a tiny black square.
,
Aug 29 2016
The following revision refers to this bug: https://chromium.googlesource.com/angle/angle/+/ab48164566a4e3d859c75196047bd688437e0307 commit ab48164566a4e3d859c75196047bd688437e0307 Author: Olli Etuaho <oetuaho@nvidia.com> Date: Fri Aug 26 09:09:10 2016 Fix splitting nested sequence operators Make sure that only one sequence operator is split on one iteration of SplitSequenceOperator. This prevents multiple successive PostVisit calls to nested sequence operator nodes from adding duplicate nodes to the AST. The sequence operators are split starting from the outermost one to preserve execution order. Note that the shader translator somewhat unexpectedly generates nested sequence operators in the AST when there is a sequence operator with more than two operands, so this bug ended up affecting shaders in the wild. The code around parsing sequence operators could be clarified separately. BUG= 638313 TEST=angle_end2end_tests Change-Id: Ic6400a484ceff0c790c2290f7b4b80980f87cd88 Reviewed-on: https://chromium-review.googlesource.com/376678 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com> [modify] https://crrev.com/ab48164566a4e3d859c75196047bd688437e0307/src/tests/gl_tests/GLSLTest.cpp [modify] https://crrev.com/ab48164566a4e3d859c75196047bd688437e0307/src/compiler/translator/SplitSequenceOperator.cpp
,
Aug 30 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/ef465a5a418b092f9eab8bf1020a46eafe527432 commit ef465a5a418b092f9eab8bf1020a46eafe527432 Author: geofflang <geofflang@chromium.org> Date: Tue Aug 30 16:08:08 2016 Roll ANGLE ca05a08..d5da505 https://chromium.googlesource.com/angle/angle.git/+log/ca05a08..d5da505 BUG= 638313 ,605754 TBR=cwallez@chromium.org TEST=bots CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.win:win_optional_gpu_tests_rel;master.tryserver.chromium.mac:mac_optional_gpu_tests_rel;master.tryserver.chromium.linux:linux_optional_gpu_tests_rel;master.tryserver.chromium.android:android_optional_gpu_tests_rel Review-Url: https://codereview.chromium.org/2296753002 Cr-Commit-Position: refs/heads/master@{#415309} [modify] https://crrev.com/ef465a5a418b092f9eab8bf1020a46eafe527432/DEPS
,
Sep 7 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/7b1cde44b479da6b87520073d9c2a95d7bb32346 commit 7b1cde44b479da6b87520073d9c2a95d7bb32346 Author: jmadill <jmadill@chromium.org> Date: Wed Sep 07 17:38:13 2016 WebGL 2: Update Windows expectations. The NVIDIA driver update should fix one test. We re-landed a fix for dynamic indexing. Try lifting the buffercopy flaky suppression. BUG= 638313 , 587601 BUG= angleproject:1246 TBR=kbr@chromium.org,zmo@chromium.org 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 Review-Url: https://codereview.chromium.org/2316233002 Cr-Commit-Position: refs/heads/master@{#416982} [modify] https://crrev.com/7b1cde44b479da6b87520073d9c2a95d7bb32346/content/test/gpu/gpu_tests/webgl2_conformance_expectations.py
,
Sep 19 2016
M54 Stable release is scheduled during the first week of OCT, please have the fix baked/verified in canary and request a merge to M54 ASAP.
,
Sep 20 2016
Fix has baked in Canary for some time, fixes customer websites, and should be safe: https://chromium-review.googlesource.com/376678
,
Sep 20 2016
[Automated comment] DEPS changes referenced in bugdroid comments, needs manual review.
,
Sep 20 2016
This change meets the bar and is approved for M54
,
Sep 20 2016
The following revision refers to this bug: https://chromium.googlesource.com/angle/angle/+/905fbdea9ef049fb0b81a46013b78f4e619c8466 commit 905fbdea9ef049fb0b81a46013b78f4e619c8466 Author: Olli Etuaho <oetuaho@nvidia.com> Date: Fri Aug 26 09:09:10 2016 Fix splitting nested sequence operators Make sure that only one sequence operator is split on one iteration of SplitSequenceOperator. This prevents multiple successive PostVisit calls to nested sequence operator nodes from adding duplicate nodes to the AST. The sequence operators are split starting from the outermost one to preserve execution order. Note that the shader translator somewhat unexpectedly generates nested sequence operators in the AST when there is a sequence operator with more than two operands, so this bug ended up affecting shaders in the wild. The code around parsing sequence operators could be clarified separately. BUG= 638313 TEST=angle_end2end_tests Change-Id: Ic6400a484ceff0c790c2290f7b4b80980f87cd88 Reviewed-on: https://chromium-review.googlesource.com/376678 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com> Reviewed-on: https://chromium-review.googlesource.com/387173 [modify] https://crrev.com/905fbdea9ef049fb0b81a46013b78f4e619c8466/src/tests/gl_tests/GLSLTest.cpp [modify] https://crrev.com/905fbdea9ef049fb0b81a46013b78f4e619c8466/src/compiler/translator/SplitSequenceOperator.cpp
,
Sep 20 2016
The following revision refers to this bug: https://chromium.googlesource.com/angle/angle/+/905fbdea9ef049fb0b81a46013b78f4e619c8466 commit 905fbdea9ef049fb0b81a46013b78f4e619c8466 Author: Olli Etuaho <oetuaho@nvidia.com> Date: Fri Aug 26 09:09:10 2016 Fix splitting nested sequence operators Make sure that only one sequence operator is split on one iteration of SplitSequenceOperator. This prevents multiple successive PostVisit calls to nested sequence operator nodes from adding duplicate nodes to the AST. The sequence operators are split starting from the outermost one to preserve execution order. Note that the shader translator somewhat unexpectedly generates nested sequence operators in the AST when there is a sequence operator with more than two operands, so this bug ended up affecting shaders in the wild. The code around parsing sequence operators could be clarified separately. BUG= 638313 TEST=angle_end2end_tests Change-Id: Ic6400a484ceff0c790c2290f7b4b80980f87cd88 Reviewed-on: https://chromium-review.googlesource.com/376678 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com> Reviewed-on: https://chromium-review.googlesource.com/387173 [modify] https://crrev.com/905fbdea9ef049fb0b81a46013b78f4e619c8466/src/tests/gl_tests/GLSLTest.cpp [modify] https://crrev.com/905fbdea9ef049fb0b81a46013b78f4e619c8466/src/compiler/translator/SplitSequenceOperator.cpp
,
Nov 4 2016
[Automated comment] removing mislabelled merge-merged-2840 |
|||||||||||||||||||||||
►
Sign in to add a comment |
|||||||||||||||||||||||
Comment 1 by kbr@chromium.org
, Aug 16 2016Components: Internals>GPU>ANGLE Blink>WebGL