Skip to content
Snippets Groups Projects
Commit 513cc4cf authored by John Kessenich's avatar John Kessenich
Browse files

Merge branch 'HaydnTrigg-patch-1'

parents 5e701954 c88edb13
No related branches found
No related tags found
No related merge requests found
...@@ -179,6 +179,10 @@ ERROR: node is still EOpNull! ...@@ -179,6 +179,10 @@ ERROR: node is still EOpNull!
0:83 2147483647 (const int) 0:83 2147483647 (const int)
0:84 Constant: 0:84 Constant:
0:84 +1.#INF 0:84 +1.#INF
0:84 Constant:
0:84 -1.#INF
0:84 Constant:
0:84 1.#IND
0:88 Constant: 0:88 Constant:
0:88 2 (const uint) 0:88 2 (const uint)
0:88 3 (const uint) 0:88 3 (const uint)
......
...@@ -81,7 +81,7 @@ void foo() ...@@ -81,7 +81,7 @@ void foo()
a[0] = s.m[1].z; // 7.0 a[0] = s.m[1].z; // 7.0
b % 0; // int b % 0; // int
b / 0; b / 0;
e / 0; e / 0; -e / 0; 0.0 / 0.0;
const uint ua = 5; const uint ua = 5;
const uvec2 ub = uvec2(6, 7); const uvec2 ub = uvec2(6, 7);
const uint uc = 8; const uint uc = 8;
......
// This header is generated by the make-revision script. // This header is generated by the make-revision script.
#define GLSLANG_PATCH_LEVEL 2787 #define GLSLANG_PATCH_LEVEL 2793
...@@ -179,7 +179,14 @@ TIntermTyped* TIntermConstantUnion::fold(TOperator op, const TIntermTyped* right ...@@ -179,7 +179,14 @@ TIntermTyped* TIntermConstantUnion::fold(TOperator op, const TIntermTyped* right
case EbtDouble: case EbtDouble:
case EbtFloat: case EbtFloat:
case EbtFloat16: case EbtFloat16:
newConstArray[i].setDConst(leftUnionArray[i].getDConst() / rightUnionArray[i].getDConst()); if (rightUnionArray[i].getDConst() != 0.0)
newConstArray[i].setDConst(leftUnionArray[i].getDConst() / rightUnionArray[i].getDConst());
else if (leftUnionArray[i].getDConst() > 0.0)
newConstArray[i].setDConst((double)INFINITY);
else if (leftUnionArray[i].getDConst() < 0.0)
newConstArray[i].setDConst((double)-INFINITY);
else
newConstArray[i].setDConst((double)NAN);
break; break;
case EbtInt8: case EbtInt8:
if (rightUnionArray[i] == (signed char)0) if (rightUnionArray[i] == (signed char)0)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment