skia2/tests/sksl
John Stiles 26fdcbb38b Implement constant folding for (bool == bool) and (bool != bool).
We already had support for &&, ||, ^^ but somehow the common cases of
== and != were not implemented in the constant-folder.

This CL also updates the test to return a green/red color on success or
failure, instead of assigning arbitrary numbers into sk_FragColor that
don't mean anything. The long-term plan is to signal success or failure
of each test by color code; we can display these colors as swatches in a
GM slide for testing purposes.

Change-Id: I0810108b3c6b656a60cd8aa64ceefd765eff0157
Bug: skia:11112
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/355984
Auto-Submit: John Stiles <johnstiles@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
2021-01-20 14:22:35 +00:00
..
blend Reorder GLSL output so that functions are emitted last. 2021-01-15 23:15:46 +00:00
errors Enforce (valid) array sizes in many more places 2021-01-14 22:14:59 +00:00
folding Implement constant folding for (bool == bool) and (bool != bool). 2021-01-20 14:22:35 +00:00
fp Allow type-fluid GLSL-style vec2(int, bool) ctors in SkSL. 2021-01-13 19:45:14 +00:00
glsl Replace array indexing on vector types with swizzles. 2020-12-07 21:16:40 +00:00
inliner Reorder GLSL output so that functions are emitted last. 2021-01-15 23:15:46 +00:00
intrinsics Generate valid Metal code when globals reference one another. 2021-01-19 17:07:24 +00:00
metal Generate valid Metal code when globals reference one another. 2021-01-19 17:07:24 +00:00
runtime Reland "Support indexing by loop variables in SkVMGenerator" 2021-01-19 22:33:46 +00:00
runtime_errors Enforce ES2 limits on indexing expressions (in runtime effects) 2021-01-15 22:49:27 +00:00
shared Implement constant folding for (bool == bool) and (bool != bool). 2021-01-20 14:22:35 +00:00
spirv Factor out SPIR-V typecasting helper functions. 2021-01-14 00:00:15 +00:00
workarounds Reorder GLSL output so that functions are emitted last. 2021-01-15 23:15:46 +00:00