Turn on SpecConstantOpMode based on node qualifier
authorqining <qining@google.com>
Mon, 4 Apr 2016 02:20:42 +0000 (22:20 -0400)
committerqining <qining@google.com>
Wed, 6 Apr 2016 16:56:31 +0000 (12:56 -0400)
commit408876600f03c19c50f1201ab8f5f28d2cd8d3fb
tree31bca8949ed5383e120344192fe2d556dac7b869
parent4c9126153d1d253f5177da772141aee8a6530ef2
Turn on SpecConstantOpMode based on node qualifier

Move SpecConstantOpModeGuard from makeSpvConstantFromConstSubTree() to
visitbinary() and visitunary(). Checking if the visiting node is a spec
constants, if so, turn on the SpecConstantOpMode, otherwise, stay in the
normal mode.
SPIRV/GlslangToSpv.cpp
Test/baseResults/spv.specConstant.comp.out
Test/baseResults/spv.specConstant.vert.out
Test/baseResults/spv.specConstantComposite.vert.out
Test/baseResults/spv.specConstantOperations.vert.out