Diff
Modified: trunk/LayoutTests/ChangeLog (284196 => 284197)
--- trunk/LayoutTests/ChangeLog 2021-10-14 21:11:35 UTC (rev 284196)
+++ trunk/LayoutTests/ChangeLog 2021-10-14 21:14:26 UTC (rev 284197)
@@ -1,3 +1,18 @@
+2021-10-14 Kyle Piddington <[email protected]>
+
+ https://tankionline.com/play/ html5 engine not working: crashes. (Metal shader not working)
+ https://bugs.webkit.org/show_bug.cgi?id=231490
+
+ Add argument to RemoveInactiveInterfaceVariables to keep
+ output fragment variables, even if they are
+ Add a new test to verify that this problem is fixed.
+
+ Reviewed by Kenneth Russell.
+
+ * webgl/pending/conformance2/glsl3/empty-shader-with-output-expected.txt: Added.
+ * webgl/pending/conformance2/glsl3/empty-shader-with-output.html: Added.
+ * webgl/pending/resources/webgl_test_files/conformance2/glsl3/empty-shader-with-output.html: Added.
+
2021-10-14 Eric Hutchison <[email protected]>
Rebaseline for fast/css/font-face-implicit-local-font.html.
Added: trunk/LayoutTests/webgl/pending/conformance2/glsl3/empty-shader-with-output-expected.txt (0 => 284197)
--- trunk/LayoutTests/webgl/pending/conformance2/glsl3/empty-shader-with-output-expected.txt (rev 0)
+++ trunk/LayoutTests/webgl/pending/conformance2/glsl3/empty-shader-with-output-expected.txt 2021-10-14 21:14:26 UTC (rev 284197)
@@ -0,0 +1,4 @@
+This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.
+
+Test: ../../resources/webgl_test_files/conformance2/glsl3/empty-shader-with-output.html?webglVersion=2
+[ PASS ] All tests passed
Added: trunk/LayoutTests/webgl/pending/conformance2/glsl3/empty-shader-with-output.html (0 => 284197)
--- trunk/LayoutTests/webgl/pending/conformance2/glsl3/empty-shader-with-output.html (rev 0)
+++ trunk/LayoutTests/webgl/pending/conformance2/glsl3/empty-shader-with-output.html 2021-10-14 21:14:26 UTC (rev 284197)
@@ -0,0 +1,18 @@
+<!-- This file is auto-generated by Tools/Scripts/update-webgl-conformance-tests. DO NOT EDIT -->
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL Conformance Test Wrapper for empty-shader-with-output.html</title>
+<script type="text/_javascript_" src=""
+<script type="text/_javascript_" src=""
+</head>
+<body>
+<p>This test runs the WebGL Test listed below in an iframe and reports PASS or FAIL.</p>
+Test: <a href=""
+<div id="iframe">
+<iframe src="" width="800" height="600"></iframe>
+</div>
+<div id="result"></div>
+</body>
+</html>
Added: trunk/LayoutTests/webgl/pending/resources/webgl_test_files/conformance2/glsl3/empty-shader-with-output.html (0 => 284197)
--- trunk/LayoutTests/webgl/pending/resources/webgl_test_files/conformance2/glsl3/empty-shader-with-output.html (rev 0)
+++ trunk/LayoutTests/webgl/pending/resources/webgl_test_files/conformance2/glsl3/empty-shader-with-output.html 2021-10-14 21:14:26 UTC (rev 284197)
@@ -0,0 +1,93 @@
+<!--
+Copyright (c) 2021 The Khronos Group Inc.
+Use of this source code is governed by an MIT-style license that can be
+found in the LICENSE.txt file.
+-->
+
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<title>WebGL GLSL Conformance Tests - Empty Shader as Output</title>
+<link rel="stylesheet" href=""
+<link rel="stylesheet" href=""
+<script src=""
+<script src=""
+<script src=""
+</head>
+<body>
+<div id="description"></div>
+<div id="console"></div>
+<!--
+Test that an empty vertex shader and fragment shader compile.
+-->
+<script id="fs0" type="text/something-not-_javascript_">#version 300 es
+precision mediump float;
+out vec4 outColor0;
+void main()
+{
+}
+</script>
+
+<script id="fs1" type="text/something-not-_javascript_">#version 300 es
+precision mediump float;
+void main()
+{
+}
+</script>
+
+<script id="vs2" type="text/something-not-_javascript_">#version 300 es
+precision mediump float;
+void main()
+{
+}
+</script>
+<script id="fs2" type="text/something-not-_javascript_">#version 300 es
+precision mediump float;
+out vec4 outColor0;
+void main()
+{
+ outColor0 = vec4(0,255,0,255);
+}
+</script>
+
+<script>
+"use strict";
+
+description();
+
+var tests = [];
+var fsrc = document.getElementById("fs0").text;
+tests.push({
+ fShaderSource: fsrc,
+ fShaderSuccess: true,
+ linkSuccess: true,
+ renderColor: [255, 255, 255, 255],
+ passMsg:`Empty fragment shader with colorOut works`
+})
+
+var fsrc1 = document.getElementById("fs1").text;
+tests.push({
+ fShaderSource: fsrc1,
+ fShaderSuccess: true,
+ linkSuccess: true,
+ renderColor: [255, 255, 255, 255],
+ passMsg: `Empty fragment shader with no output works`
+})
+
+var vsrc2 = document.getElementById("vs2").text;
+var fsrc2 = document.getElementById("fs2").text;
+tests.push({
+ vShaderSource: vsrc2,
+ vShaderSuccess: true,
+ fShaderSource: fsrc2,
+ fShaderSuccess: true,
+ linkSuccess: true,
+ renderColor: [255, 255, 255, 255],
+ passMsg: `Empty Vertex shader works`
+})
+
+GLSLConformanceTester.runRenderTests(tests, 2);
+</script>
+</body>
+</html>
Modified: trunk/Source/ThirdParty/ANGLE/ChangeLog (284196 => 284197)
--- trunk/Source/ThirdParty/ANGLE/ChangeLog 2021-10-14 21:11:35 UTC (rev 284196)
+++ trunk/Source/ThirdParty/ANGLE/ChangeLog 2021-10-14 21:14:26 UTC (rev 284197)
@@ -1,3 +1,22 @@
+2021-10-14 Kyle Piddington <[email protected]>
+
+ https://tankionline.com/play/ html5 engine not working: crashes. (Metal shader not working)
+ https://bugs.webkit.org/show_bug.cgi?id=231490
+
+ Add argument to RemoveInactiveInterfaceVariables to keep
+ output fragment variables, even if they are
+ Add a new test to verify that this problem is fixed.
+
+ Reviewed by Kenneth Russell.
+
+ * src/compiler/translator/TranslatorMetalDirect.cpp:
+ (sh::TranslatorMetalDirect::translateImpl):
+ * src/compiler/translator/TranslatorVulkan.cpp:
+ (sh::TranslatorVulkan::translateImpl):
+ * src/compiler/translator/tree_ops/RemoveInactiveInterfaceVariables.cpp:
+ (sh::RemoveInactiveInterfaceVariables):
+ * src/compiler/translator/tree_ops/RemoveInactiveInterfaceVariables.h:
+
2021-10-14 Myles C. Maxfield <[email protected]>
All the SDKVariant.xcconfig files should match
Modified: trunk/Source/ThirdParty/ANGLE/src/compiler/translator/TranslatorMetalDirect.cpp (284196 => 284197)
--- trunk/Source/ThirdParty/ANGLE/src/compiler/translator/TranslatorMetalDirect.cpp 2021-10-14 21:11:35 UTC (rev 284196)
+++ trunk/Source/ThirdParty/ANGLE/src/compiler/translator/TranslatorMetalDirect.cpp 2021-10-14 21:14:26 UTC (rev 284197)
@@ -865,7 +865,7 @@
// Strip any inactive variables from the program.
if (!RemoveInactiveInterfaceVariables(this, &root, getAttributes(), getInputVaryings(),
getOutputVariables(), getUniforms(),
- getInterfaceBlocks()))
+ getInterfaceBlocks(), false))
{
return false;
}
Modified: trunk/Source/ThirdParty/ANGLE/src/compiler/translator/TranslatorVulkan.cpp (284196 => 284197)
--- trunk/Source/ThirdParty/ANGLE/src/compiler/translator/TranslatorVulkan.cpp 2021-10-14 21:11:35 UTC (rev 284196)
+++ trunk/Source/ThirdParty/ANGLE/src/compiler/translator/TranslatorVulkan.cpp 2021-10-14 21:14:26 UTC (rev 284197)
@@ -798,7 +798,7 @@
// is inactive.
if (!RemoveInactiveInterfaceVariables(this, root, getAttributes(), getInputVaryings(),
getOutputVariables(), getUniforms(),
- getInterfaceBlocks()))
+ getInterfaceBlocks(), true))
{
return false;
}
Modified: trunk/Source/ThirdParty/ANGLE/src/compiler/translator/tree_ops/RemoveInactiveInterfaceVariables.cpp (284196 => 284197)
--- trunk/Source/ThirdParty/ANGLE/src/compiler/translator/tree_ops/RemoveInactiveInterfaceVariables.cpp 2021-10-14 21:11:35 UTC (rev 284196)
+++ trunk/Source/ThirdParty/ANGLE/src/compiler/translator/tree_ops/RemoveInactiveInterfaceVariables.cpp 2021-10-14 21:14:26 UTC (rev 284197)
@@ -28,7 +28,8 @@
const std::vector<sh::ShaderVariable> &inputVaryings,
const std::vector<sh::ShaderVariable> &outputVariables,
const std::vector<sh::ShaderVariable> &uniforms,
- const std::vector<sh::InterfaceBlock> &interfaceBlocks);
+ const std::vector<sh::InterfaceBlock> &interfaceBlocks,
+ bool removeFragmentOutputs);
bool visitDeclaration(Visit visit, TIntermDeclaration *node) override;
@@ -38,6 +39,7 @@
const std::vector<sh::ShaderVariable> &mOutputVariables;
const std::vector<sh::ShaderVariable> &mUniforms;
const std::vector<sh::InterfaceBlock> &mInterfaceBlocks;
+ bool mRemoveFragmentOutputs;
};
RemoveInactiveInterfaceVariablesTraverser::RemoveInactiveInterfaceVariablesTraverser(
@@ -45,13 +47,15 @@
const std::vector<sh::ShaderVariable> &inputVaryings,
const std::vector<sh::ShaderVariable> &outputVariables,
const std::vector<sh::ShaderVariable> &uniforms,
- const std::vector<sh::InterfaceBlock> &interfaceBlocks)
+ const std::vector<sh::InterfaceBlock> &interfaceBlocks,
+ bool removeFragmentOutputs)
: TIntermTraverser(true, false, false),
mAttributes(attributes),
mInputVaryings(inputVaryings),
mOutputVariables(outputVariables),
mUniforms(uniforms),
- mInterfaceBlocks(interfaceBlocks)
+ mInterfaceBlocks(interfaceBlocks),
+ mRemoveFragmentOutputs(removeFragmentOutputs)
{}
template <typename Variable>
@@ -115,7 +119,7 @@
}
else if (qualifier == EvqFragmentOut)
{
- removeDeclaration = !IsVariableActive(mOutputVariables, asSymbol->getName());
+ removeDeclaration = !IsVariableActive(mOutputVariables, asSymbol->getName()) && mRemoveFragmentOutputs;
}
if (removeDeclaration)
@@ -135,10 +139,11 @@
const std::vector<sh::ShaderVariable> &inputVaryings,
const std::vector<sh::ShaderVariable> &outputVariables,
const std::vector<sh::ShaderVariable> &uniforms,
- const std::vector<sh::InterfaceBlock> &interfaceBlocks)
+ const std::vector<sh::InterfaceBlock> &interfaceBlocks,
+ bool removeFragmentOutputs)
{
RemoveInactiveInterfaceVariablesTraverser traverser(attributes, inputVaryings, outputVariables,
- uniforms, interfaceBlocks);
+ uniforms, interfaceBlocks, removeFragmentOutputs);
root->traverse(&traverser);
return traverser.updateTree(compiler, root);
}
Modified: trunk/Source/ThirdParty/ANGLE/src/compiler/translator/tree_ops/RemoveInactiveInterfaceVariables.h (284196 => 284197)
--- trunk/Source/ThirdParty/ANGLE/src/compiler/translator/tree_ops/RemoveInactiveInterfaceVariables.h 2021-10-14 21:11:35 UTC (rev 284196)
+++ trunk/Source/ThirdParty/ANGLE/src/compiler/translator/tree_ops/RemoveInactiveInterfaceVariables.h 2021-10-14 21:14:26 UTC (rev 284197)
@@ -33,7 +33,8 @@
const std::vector<sh::ShaderVariable> &inputVaryings,
const std::vector<sh::ShaderVariable> &outputVariables,
const std::vector<sh::ShaderVariable> &uniforms,
- const std::vector<sh::InterfaceBlock> &interfaceBlocks);
+ const std::vector<sh::InterfaceBlock> &interfaceBlocks,
+ bool removeFragmentOutputs);
} // namespace sh