aboutsummaryrefslogtreecommitdiff
path: root/SPIRV/GlslangToSpv.cpp
diff options
context:
space:
mode:
authorRex Xu <rex.xu@amd.com>2016-07-29 16:13:04 +0800
committerRex Xu <rex.xu@amd.com>2016-07-29 16:13:04 +0800
commitce31aea0d09f32914e1e01695b7b08bf5d7310a8 (patch)
tree2091dfb0da60d26bbe11a58f68ed2abc313813b7 /SPIRV/GlslangToSpv.cpp
parent64076ed7e90956c892e7106a8989b5cd40c2370e (diff)
downloadglslang-ce31aea0d09f32914e1e01695b7b08bf5d7310a8.tar.gz
SPV: Fix an issue of ++/-- for dvec/dmat.
Diffstat (limited to 'SPIRV/GlslangToSpv.cpp')
-rwxr-xr-xSPIRV/GlslangToSpv.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/SPIRV/GlslangToSpv.cpp b/SPIRV/GlslangToSpv.cpp
index 26d2f4bc..470ed253 100755
--- a/SPIRV/GlslangToSpv.cpp
+++ b/SPIRV/GlslangToSpv.cpp
@@ -1174,6 +1174,8 @@ bool TGlslangToSpvTraverser::visitUnary(glslang::TVisit /* visit */, glslang::TI
spv::Id one = 0;
if (node->getBasicType() == glslang::EbtFloat)
one = builder.makeFloatConstant(1.0F);
+ else if (node->getBasicType() == glslang::EbtDouble)
+ one = builder.makeDoubleConstant(1.0);
else if (node->getBasicType() == glslang::EbtInt64 || node->getBasicType() == glslang::EbtUint64)
one = builder.makeInt64Constant(1);
else