Browse Source

Updated glslang.

Branimir Karadžić 7 years ago
parent
commit
f32163520b
91 changed files with 1111 additions and 794 deletions
  1. 8 0
      3rdparty/glslang/CMakeLists.txt
  2. 7 2
      3rdparty/glslang/SPIRV/CMakeLists.txt
  3. 3 3
      3rdparty/glslang/SPIRV/GlslangToSpv.cpp
  4. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.calculatelod.dx10.frag.out
  5. 2 0
      3rdparty/glslang/Test/baseResults/hlsl.calculatelodunclamped.dx10.frag.out
  6. 1 0
      3rdparty/glslang/Test/baseResults/hlsl.depthGreater.frag.out
  7. 1 0
      3rdparty/glslang/Test/baseResults/hlsl.depthLess.frag.out
  8. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.gather.array.dx10.frag.out
  9. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.gather.basic.dx10.frag.out
  10. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.gather.offset.dx10.frag.out
  11. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.gather.offsetarray.dx10.frag.out
  12. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.gatherRGBA.array.dx10.frag.out
  13. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.gatherRGBA.basic.dx10.frag.out
  14. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.gatherRGBA.offset.dx10.frag.out
  15. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.gatherRGBA.offsetarray.dx10.frag.out
  16. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.gathercmpRGBA.offset.dx10.frag.out
  17. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.getdimensions.dx10.frag.out
  18. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.getdimensions.rw.dx10.frag.out
  19. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.getsampleposition.dx10.frag.out
  20. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.inoutquals.frag.out
  21. 72 72
      3rdparty/glslang/Test/baseResults/hlsl.intrinsics.comp.out
  22. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.load.2dms.dx10.frag.out
  23. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.load.array.dx10.frag.out
  24. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.load.basic.dx10.frag.out
  25. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.load.buffer.dx10.frag.out
  26. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.load.buffer.float.dx10.frag.out
  27. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.load.offset.dx10.frag.out
  28. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.load.offsetarray.dx10.frag.out
  29. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.load.rwtexture.array.dx10.frag.out
  30. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.load.rwtexture.dx10.frag.out
  31. 23 24
      3rdparty/glslang/Test/baseResults/hlsl.noSemantic.functionality1.comp.out
  32. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.pp.line.frag.out
  33. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.sample.array.dx10.frag.out
  34. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.sample.basic.dx10.frag.out
  35. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.sample.offset.dx10.frag.out
  36. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.sample.offsetarray.dx10.frag.out
  37. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.samplebias.array.dx10.frag.out
  38. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.samplebias.basic.dx10.frag.out
  39. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.samplebias.offset.dx10.frag.out
  40. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.samplebias.offsetarray.dx10.frag.out
  41. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.samplecmp.array.dx10.frag.out
  42. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.samplecmp.basic.dx10.frag.out
  43. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.samplecmp.offset.dx10.frag.out
  44. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.samplecmp.offsetarray.dx10.frag.out
  45. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.samplecmplevelzero.array.dx10.frag.out
  46. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.samplecmplevelzero.basic.dx10.frag.out
  47. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.samplecmplevelzero.offset.dx10.frag.out
  48. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.samplecmplevelzero.offsetarray.dx10.frag.out
  49. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.samplegrad.array.dx10.frag.out
  50. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.samplegrad.basic.dx10.frag.out
  51. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.samplegrad.offset.dx10.frag.out
  52. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.samplegrad.offsetarray.dx10.frag.out
  53. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.samplelevel.array.dx10.frag.out
  54. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.samplelevel.basic.dx10.frag.out
  55. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.samplelevel.offset.dx10.frag.out
  56. 3 0
      3rdparty/glslang/Test/baseResults/hlsl.samplelevel.offsetarray.dx10.frag.out
  57. 1 0
      3rdparty/glslang/Test/baseResults/hlsl.structIoFourWay.frag.out
  58. 56 56
      3rdparty/glslang/Test/baseResults/hlsl.structbuffer.append.fn.frag.out
  59. 41 41
      3rdparty/glslang/Test/baseResults/hlsl.structbuffer.append.frag.out
  60. 18 18
      3rdparty/glslang/Test/baseResults/hlsl.structbuffer.atomics.frag.out
  61. 86 85
      3rdparty/glslang/Test/baseResults/hlsl.structbuffer.floatidx.comp.out
  62. 45 45
      3rdparty/glslang/Test/baseResults/hlsl.structbuffer.fn.frag.out
  63. 19 19
      3rdparty/glslang/Test/baseResults/hlsl.structbuffer.incdec.frag.hlslfun1.out
  64. 34 34
      3rdparty/glslang/Test/baseResults/hlsl.structbuffer.incdec.frag.out
  65. 1 0
      3rdparty/glslang/Test/baseResults/remap.hlsl.sample.basic.everything.frag.out
  66. 1 0
      3rdparty/glslang/Test/baseResults/remap.hlsl.sample.basic.none.frag.out
  67. 1 0
      3rdparty/glslang/Test/baseResults/remap.hlsl.sample.basic.strip.frag.out
  68. 1 1
      3rdparty/glslang/Test/baseResults/spv.GeometryShaderPassthrough.geom.out
  69. 16 9
      3rdparty/glslang/Test/baseResults/spv.noBuiltInLoc.vert.out
  70. 38 40
      3rdparty/glslang/Test/baseResults/spv.ssboAlias.frag.out
  71. 87 0
      3rdparty/glslang/Test/baseResults/spv.vecMatConstruct.frag.out
  72. 2 1
      3rdparty/glslang/Test/baseResults/vulkan.vert.out
  73. 2 0
      3rdparty/glslang/Test/spv.noBuiltInLoc.vert
  74. 14 0
      3rdparty/glslang/Test/spv.vecMatConstruct.frag
  75. 2 0
      3rdparty/glslang/Test/vulkan.vert
  76. 6 1
      3rdparty/glslang/glslang/CMakeLists.txt
  77. 13 12
      3rdparty/glslang/glslang/Include/Common.h
  78. 1 1
      3rdparty/glslang/glslang/Include/revision.h
  79. 1 0
      3rdparty/glslang/glslang/MachineIndependent/Intermediate.cpp
  80. 37 1
      3rdparty/glslang/glslang/MachineIndependent/ParseHelper.cpp
  81. 12 27
      3rdparty/glslang/glslang/MachineIndependent/ShaderLang.cpp
  82. 4 4
      3rdparty/glslang/glslang/MachineIndependent/Versions.cpp
  83. 144 144
      3rdparty/glslang/glslang/MachineIndependent/glslang.y
  84. 144 144
      3rdparty/glslang/glslang/MachineIndependent/glslang_tab.cpp
  85. 1 0
      3rdparty/glslang/glslang/MachineIndependent/iomapper.cpp
  86. 2 2
      3rdparty/glslang/glslang/MachineIndependent/linkValidate.cpp
  87. 1 1
      3rdparty/glslang/glslang/Public/ShaderLang.h
  88. 1 0
      3rdparty/glslang/gtests/Spv.FromFile.cpp
  89. 5 1
      3rdparty/glslang/hlsl/CMakeLists.txt
  90. 11 4
      3rdparty/glslang/hlsl/hlslParseHelper.cpp
  91. 2 2
      3rdparty/glslang/known_good.json

+ 8 - 0
3rdparty/glslang/CMakeLists.txt

@@ -9,6 +9,14 @@ set_property(GLOBAL PROPERTY USE_FOLDERS ON)
 # Adhere to GNU filesystem layout conventions
 include(GNUInstallDirs)
 
+option(BUILD_SHARED_LIBS "Build Shared Libraries" OFF)
+
+set(LIB_TYPE STATIC)
+
+if(BUILD_SHARED_LIBS)
+    set(LIB_TYPE SHARED)
+endif()
+
 option(SKIP_GLSLANG_INSTALL "Skip installation" ${SKIP_GLSLANG_INSTALL})
 if(NOT ${SKIP_GLSLANG_INSTALL})
   set(ENABLE_GLSLANG_INSTALL ON)

+ 7 - 2
3rdparty/glslang/SPIRV/CMakeLists.txt

@@ -40,14 +40,19 @@ if(ENABLE_NV_EXTENSIONS)
          GLSL.ext.NV.h)
 endif(ENABLE_NV_EXTENSIONS)
 
-add_library(SPIRV STATIC ${SOURCES} ${HEADERS})
+add_library(SPIRV ${LIB_TYPE} ${SOURCES} ${HEADERS})
 set_property(TARGET SPIRV PROPERTY FOLDER glslang)
 set_property(TARGET SPIRV PROPERTY POSITION_INDEPENDENT_CODE ON)
 
-add_library(SPVRemapper STATIC ${SPVREMAP_SOURCES} ${SPVREMAP_HEADERS})
+add_library(SPVRemapper ${LIB_TYPE} ${SPVREMAP_SOURCES} ${SPVREMAP_HEADERS})
 set_property(TARGET SPVRemapper PROPERTY FOLDER glslang)
 set_property(TARGET SPVRemapper PROPERTY POSITION_INDEPENDENT_CODE ON)
 
+if(WIN32 AND BUILD_SHARED_LIBS)
+    set_target_properties(SPIRV PROPERTIES PREFIX "")
+    set_target_properties(SPVRemapper PROPERTIES PREFIX "")
+endif()
+
 if(ENABLE_OPT)
     target_include_directories(SPIRV
         PRIVATE ${spirv-tools_SOURCE_DIR}/include

+ 3 - 3
3rdparty/glslang/SPIRV/GlslangToSpv.cpp

@@ -3638,7 +3638,7 @@ spv::Id TGlslangToSpvTraverser::createImageTextureFunctionCall(glslang::TIntermO
             if (builder.getImageTypeFormat(builder.getImageType(operands.front())) == spv::ImageFormatUnknown)
                 builder.addCapability(spv::CapabilityStorageImageReadWithoutFormat);
 
-            std::vector<spv::Id> result = { builder.createOp(spv::OpImageRead, resultType(), operands) };
+            std::vector<spv::Id> result( 1, builder.createOp(spv::OpImageRead, resultType(), operands) );
             builder.setPrecision(result[0], precision);
 
             // If needed, add a conversion constructor to the proper size.
@@ -3926,9 +3926,9 @@ spv::Id TGlslangToSpvTraverser::createImageTextureFunctionCall(glslang::TIntermO
         }
     }
 
-    std::vector<spv::Id> result = { 
+    std::vector<spv::Id> result( 1, 
         builder.createTextureCall(precision, resultType(), sparse, cracked.fetch, cracked.proj, cracked.gather, noImplicitLod, params)
-    };
+    );
 
     if (components != node->getType().getVectorSize())
         result[0] = builder.createConstructor(precision, result, convertGlslangToSpvType(node->getType()));

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.calculatelod.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.calculatelod.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:24  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:24    Function Parameters: 
@@ -181,6 +182,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:24  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:24    Function Parameters: 
@@ -367,6 +369,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 140 144
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 2 - 0
3rdparty/glslang/Test/baseResults/hlsl.calculatelodunclamped.dx10.frag.out

@@ -13,6 +13,7 @@ ERROR: 9 compilation errors.  No code generated.
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 ERROR: node is still EOpNull!
 0:24  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:24    Function Parameters: 
@@ -193,6 +194,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 ERROR: node is still EOpNull!
 0:24  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:24    Function Parameters: 

+ 1 - 0
3rdparty/glslang/Test/baseResults/hlsl.depthGreater.frag.out

@@ -59,6 +59,7 @@ using depth_greater
                               EntryPoint Fragment 4  "PixelShaderFunction" 18
                               ExecutionMode 4 OriginUpperLeft
                               ExecutionMode 4 DepthGreater
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "PixelShaderFunction"
                               Name 10  "@PixelShaderFunction(f1;"

+ 1 - 0
3rdparty/glslang/Test/baseResults/hlsl.depthLess.frag.out

@@ -51,6 +51,7 @@ using depth_less
                               EntryPoint Fragment 4  "PixelShaderFunction" 14
                               ExecutionMode 4 OriginUpperLeft
                               ExecutionMode 4 DepthLess
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "PixelShaderFunction"
                               Name 8  "@PixelShaderFunction("

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.gather.array.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.gather.array.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:24  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:24    Function Parameters: 
@@ -133,6 +134,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:24  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:24    Function Parameters: 
@@ -270,6 +272,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 107 111
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.gather.basic.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.gather.basic.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:29  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:29    Function Parameters: 
@@ -131,6 +132,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:29  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:29    Function Parameters: 
@@ -265,6 +267,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 108 112
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.gather.offset.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.gather.offset.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:28  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:28    Function Parameters: 
@@ -106,6 +107,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:28  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:28    Function Parameters: 
@@ -215,6 +217,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 79 83
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.gather.offsetarray.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.gather.offsetarray.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:20  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:20    Function Parameters: 
@@ -103,6 +104,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:20  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:20    Function Parameters: 
@@ -209,6 +211,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 80 84
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.gatherRGBA.array.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.gatherRGBA.array.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:28  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:28    Function Parameters: 
@@ -377,6 +378,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:28  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:28    Function Parameters: 
@@ -758,6 +760,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 238 242
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.gatherRGBA.basic.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.gatherRGBA.basic.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:34  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:34    Function Parameters: 
@@ -381,6 +382,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:34  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:34    Function Parameters: 
@@ -765,6 +767,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 238 242
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.gatherRGBA.offset.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.gatherRGBA.offset.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:39  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:39    Function Parameters: 
@@ -633,6 +634,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:39  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:39    Function Parameters: 
@@ -1270,6 +1272,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 363 367
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.gatherRGBA.offsetarray.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.gatherRGBA.offsetarray.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:33  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:33    Function Parameters: 
@@ -629,6 +630,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:33  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:33    Function Parameters: 
@@ -1263,6 +1265,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 363 367
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.gathercmpRGBA.offset.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.gathercmpRGBA.offset.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:38  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:38    Function Parameters: 
@@ -230,6 +231,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:38  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:38    Function Parameters: 
@@ -463,6 +465,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 129 133
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.getdimensions.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.getdimensions.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:46  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:46    Function Parameters: 
@@ -1161,6 +1162,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:46  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:46    Function Parameters: 
@@ -2327,6 +2329,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 540 544
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.getdimensions.rw.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.getdimensions.rw.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:44  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:44    Function Parameters: 
@@ -361,6 +362,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:44  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:44    Function Parameters: 
@@ -727,6 +729,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 216 220
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.getsampleposition.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.getsampleposition.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:13  Function Definition: @main(i1; ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:13    Function Parameters: 
@@ -292,6 +293,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:13  Function Definition: @main(i1; ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:13    Function Parameters: 
@@ -587,6 +589,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 181 188 192
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 10  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.inoutquals.frag.out

@@ -1,6 +1,7 @@
 hlsl.inoutquals.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:8  Function Definition: MyFunc(f1;f1;f1;f1; ( temp void)
 0:8    Function Parameters: 
@@ -106,6 +107,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:8  Function Definition: MyFunc(f1;f1;f1;f1; ( temp void)
 0:8    Function Parameters: 
@@ -214,6 +216,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 68 78 82 86
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 13  "MyFunc(f1;f1;f1;f1;"

+ 72 - 72
3rdparty/glslang/Test/baseResults/hlsl.intrinsics.comp.out

@@ -13,7 +13,7 @@ local_size = (1, 1, 1)
 0:21      all ( temp bool)
 0:21        Convert float to bool ( temp bool)
 0:21          'inF0' ( in float)
-0:24      AtomicAdd ( temp void)
+0:24      AtomicAdd ( temp uint)
 0:24        'gs_ua' ( shared uint)
 0:24        'gs_ub' ( shared uint)
 0:25      move second child to first child ( temp uint)
@@ -21,7 +21,7 @@ local_size = (1, 1, 1)
 0:25        AtomicAdd ( temp uint)
 0:25          'gs_ua' ( shared uint)
 0:25          'gs_ub' ( shared uint)
-0:26      AtomicAnd ( temp void)
+0:26      AtomicAnd ( temp uint)
 0:26        'gs_ua' ( shared uint)
 0:26        'gs_ub' ( shared uint)
 0:27      move second child to first child ( temp uint)
@@ -40,7 +40,7 @@ local_size = (1, 1, 1)
 0:29        AtomicExchange ( temp uint)
 0:29          'gs_ua' ( shared uint)
 0:29          'gs_ub' ( shared uint)
-0:30      AtomicMax ( temp void)
+0:30      AtomicMax ( temp uint)
 0:30        'gs_ua' ( shared uint)
 0:30        'gs_ub' ( shared uint)
 0:31      move second child to first child ( temp uint)
@@ -48,7 +48,7 @@ local_size = (1, 1, 1)
 0:31        AtomicMax ( temp uint)
 0:31          'gs_ua' ( shared uint)
 0:31          'gs_ub' ( shared uint)
-0:32      AtomicMin ( temp void)
+0:32      AtomicMin ( temp uint)
 0:32        'gs_ua' ( shared uint)
 0:32        'gs_ub' ( shared uint)
 0:33      move second child to first child ( temp uint)
@@ -56,7 +56,7 @@ local_size = (1, 1, 1)
 0:33        AtomicMin ( temp uint)
 0:33          'gs_ua' ( shared uint)
 0:33          'gs_ub' ( shared uint)
-0:34      AtomicOr ( temp void)
+0:34      AtomicOr ( temp uint)
 0:34        'gs_ua' ( shared uint)
 0:34        'gs_ub' ( shared uint)
 0:35      move second child to first child ( temp uint)
@@ -64,7 +64,7 @@ local_size = (1, 1, 1)
 0:35        AtomicOr ( temp uint)
 0:35          'gs_ua' ( shared uint)
 0:35          'gs_ub' ( shared uint)
-0:36      AtomicXor ( temp void)
+0:36      AtomicXor ( temp uint)
 0:36        'gs_ua' ( shared uint)
 0:36        'gs_ub' ( shared uint)
 0:37      move second child to first child ( temp uint)
@@ -95,7 +95,7 @@ local_size = (1, 1, 1)
 0:55      all ( temp bool)
 0:55        Convert float to bool ( temp 2-component vector of bool)
 0:55          'inF0' ( in 2-component vector of float)
-0:58      AtomicAdd ( temp void)
+0:58      AtomicAdd ( temp 2-component vector of uint)
 0:58        'gs_ua2' ( shared 2-component vector of uint)
 0:58        'gs_ub2' ( shared 2-component vector of uint)
 0:59      move second child to first child ( temp 2-component vector of uint)
@@ -103,7 +103,7 @@ local_size = (1, 1, 1)
 0:59        AtomicAdd ( temp 2-component vector of uint)
 0:59          'gs_ua2' ( shared 2-component vector of uint)
 0:59          'gs_ub2' ( shared 2-component vector of uint)
-0:60      AtomicAnd ( temp void)
+0:60      AtomicAnd ( temp 2-component vector of uint)
 0:60        'gs_ua2' ( shared 2-component vector of uint)
 0:60        'gs_ub2' ( shared 2-component vector of uint)
 0:61      move second child to first child ( temp 2-component vector of uint)
@@ -122,7 +122,7 @@ local_size = (1, 1, 1)
 0:63        AtomicExchange ( temp 2-component vector of uint)
 0:63          'gs_ua2' ( shared 2-component vector of uint)
 0:63          'gs_ub2' ( shared 2-component vector of uint)
-0:64      AtomicMax ( temp void)
+0:64      AtomicMax ( temp 2-component vector of uint)
 0:64        'gs_ua2' ( shared 2-component vector of uint)
 0:64        'gs_ub2' ( shared 2-component vector of uint)
 0:65      move second child to first child ( temp 2-component vector of uint)
@@ -130,7 +130,7 @@ local_size = (1, 1, 1)
 0:65        AtomicMax ( temp 2-component vector of uint)
 0:65          'gs_ua2' ( shared 2-component vector of uint)
 0:65          'gs_ub2' ( shared 2-component vector of uint)
-0:66      AtomicMin ( temp void)
+0:66      AtomicMin ( temp 2-component vector of uint)
 0:66        'gs_ua2' ( shared 2-component vector of uint)
 0:66        'gs_ub2' ( shared 2-component vector of uint)
 0:67      move second child to first child ( temp 2-component vector of uint)
@@ -138,7 +138,7 @@ local_size = (1, 1, 1)
 0:67        AtomicMin ( temp 2-component vector of uint)
 0:67          'gs_ua2' ( shared 2-component vector of uint)
 0:67          'gs_ub2' ( shared 2-component vector of uint)
-0:68      AtomicOr ( temp void)
+0:68      AtomicOr ( temp 2-component vector of uint)
 0:68        'gs_ua2' ( shared 2-component vector of uint)
 0:68        'gs_ub2' ( shared 2-component vector of uint)
 0:69      move second child to first child ( temp 2-component vector of uint)
@@ -146,7 +146,7 @@ local_size = (1, 1, 1)
 0:69        AtomicOr ( temp 2-component vector of uint)
 0:69          'gs_ua2' ( shared 2-component vector of uint)
 0:69          'gs_ub2' ( shared 2-component vector of uint)
-0:70      AtomicXor ( temp void)
+0:70      AtomicXor ( temp 2-component vector of uint)
 0:70        'gs_ua2' ( shared 2-component vector of uint)
 0:70        'gs_ub2' ( shared 2-component vector of uint)
 0:71      move second child to first child ( temp 2-component vector of uint)
@@ -169,7 +169,7 @@ local_size = (1, 1, 1)
 0:82      all ( temp bool)
 0:82        Convert float to bool ( temp 3-component vector of bool)
 0:82          'inF0' ( in 3-component vector of float)
-0:85      AtomicAdd ( temp void)
+0:85      AtomicAdd ( temp 3-component vector of uint)
 0:85        'gs_ua3' ( shared 3-component vector of uint)
 0:85        'gs_ub3' ( shared 3-component vector of uint)
 0:86      move second child to first child ( temp 3-component vector of uint)
@@ -177,7 +177,7 @@ local_size = (1, 1, 1)
 0:86        AtomicAdd ( temp 3-component vector of uint)
 0:86          'gs_ua3' ( shared 3-component vector of uint)
 0:86          'gs_ub3' ( shared 3-component vector of uint)
-0:87      AtomicAnd ( temp void)
+0:87      AtomicAnd ( temp 3-component vector of uint)
 0:87        'gs_ua3' ( shared 3-component vector of uint)
 0:87        'gs_ub3' ( shared 3-component vector of uint)
 0:88      move second child to first child ( temp 3-component vector of uint)
@@ -196,7 +196,7 @@ local_size = (1, 1, 1)
 0:90        AtomicExchange ( temp 3-component vector of uint)
 0:90          'gs_ua3' ( shared 3-component vector of uint)
 0:90          'gs_ub3' ( shared 3-component vector of uint)
-0:91      AtomicMax ( temp void)
+0:91      AtomicMax ( temp 3-component vector of uint)
 0:91        'gs_ua3' ( shared 3-component vector of uint)
 0:91        'gs_ub3' ( shared 3-component vector of uint)
 0:92      move second child to first child ( temp 3-component vector of uint)
@@ -204,7 +204,7 @@ local_size = (1, 1, 1)
 0:92        AtomicMax ( temp 3-component vector of uint)
 0:92          'gs_ua3' ( shared 3-component vector of uint)
 0:92          'gs_ub3' ( shared 3-component vector of uint)
-0:93      AtomicMin ( temp void)
+0:93      AtomicMin ( temp 3-component vector of uint)
 0:93        'gs_ua3' ( shared 3-component vector of uint)
 0:93        'gs_ub3' ( shared 3-component vector of uint)
 0:94      move second child to first child ( temp 3-component vector of uint)
@@ -212,7 +212,7 @@ local_size = (1, 1, 1)
 0:94        AtomicMin ( temp 3-component vector of uint)
 0:94          'gs_ua3' ( shared 3-component vector of uint)
 0:94          'gs_ub3' ( shared 3-component vector of uint)
-0:95      AtomicOr ( temp void)
+0:95      AtomicOr ( temp 3-component vector of uint)
 0:95        'gs_ua3' ( shared 3-component vector of uint)
 0:95        'gs_ub3' ( shared 3-component vector of uint)
 0:96      move second child to first child ( temp 3-component vector of uint)
@@ -220,7 +220,7 @@ local_size = (1, 1, 1)
 0:96        AtomicOr ( temp 3-component vector of uint)
 0:96          'gs_ua3' ( shared 3-component vector of uint)
 0:96          'gs_ub3' ( shared 3-component vector of uint)
-0:97      AtomicXor ( temp void)
+0:97      AtomicXor ( temp 3-component vector of uint)
 0:97        'gs_ua3' ( shared 3-component vector of uint)
 0:97        'gs_ub3' ( shared 3-component vector of uint)
 0:98      move second child to first child ( temp 3-component vector of uint)
@@ -244,7 +244,7 @@ local_size = (1, 1, 1)
 0:109      all ( temp bool)
 0:109        Convert float to bool ( temp 4-component vector of bool)
 0:109          'inF0' ( in 4-component vector of float)
-0:112      AtomicAdd ( temp void)
+0:112      AtomicAdd ( temp 4-component vector of uint)
 0:112        'gs_ua4' ( shared 4-component vector of uint)
 0:112        'gs_ub4' ( shared 4-component vector of uint)
 0:113      move second child to first child ( temp 4-component vector of uint)
@@ -252,7 +252,7 @@ local_size = (1, 1, 1)
 0:113        AtomicAdd ( temp 4-component vector of uint)
 0:113          'gs_ua4' ( shared 4-component vector of uint)
 0:113          'gs_ub4' ( shared 4-component vector of uint)
-0:114      AtomicAnd ( temp void)
+0:114      AtomicAnd ( temp 4-component vector of uint)
 0:114        'gs_ua4' ( shared 4-component vector of uint)
 0:114        'gs_ub4' ( shared 4-component vector of uint)
 0:115      move second child to first child ( temp 4-component vector of uint)
@@ -271,7 +271,7 @@ local_size = (1, 1, 1)
 0:117        AtomicExchange ( temp 4-component vector of uint)
 0:117          'gs_ua4' ( shared 4-component vector of uint)
 0:117          'gs_ub4' ( shared 4-component vector of uint)
-0:118      AtomicMax ( temp void)
+0:118      AtomicMax ( temp 4-component vector of uint)
 0:118        'gs_ua4' ( shared 4-component vector of uint)
 0:118        'gs_ub4' ( shared 4-component vector of uint)
 0:119      move second child to first child ( temp 4-component vector of uint)
@@ -279,7 +279,7 @@ local_size = (1, 1, 1)
 0:119        AtomicMax ( temp 4-component vector of uint)
 0:119          'gs_ua4' ( shared 4-component vector of uint)
 0:119          'gs_ub4' ( shared 4-component vector of uint)
-0:120      AtomicMin ( temp void)
+0:120      AtomicMin ( temp 4-component vector of uint)
 0:120        'gs_ua4' ( shared 4-component vector of uint)
 0:120        'gs_ub4' ( shared 4-component vector of uint)
 0:121      move second child to first child ( temp 4-component vector of uint)
@@ -287,7 +287,7 @@ local_size = (1, 1, 1)
 0:121        AtomicMin ( temp 4-component vector of uint)
 0:121          'gs_ua4' ( shared 4-component vector of uint)
 0:121          'gs_ub4' ( shared 4-component vector of uint)
-0:122      AtomicOr ( temp void)
+0:122      AtomicOr ( temp 4-component vector of uint)
 0:122        'gs_ua4' ( shared 4-component vector of uint)
 0:122        'gs_ub4' ( shared 4-component vector of uint)
 0:123      move second child to first child ( temp 4-component vector of uint)
@@ -295,7 +295,7 @@ local_size = (1, 1, 1)
 0:123        AtomicOr ( temp 4-component vector of uint)
 0:123          'gs_ua4' ( shared 4-component vector of uint)
 0:123          'gs_ub4' ( shared 4-component vector of uint)
-0:124      AtomicXor ( temp void)
+0:124      AtomicXor ( temp 4-component vector of uint)
 0:124        'gs_ua4' ( shared 4-component vector of uint)
 0:124        'gs_ub4' ( shared 4-component vector of uint)
 0:125      move second child to first child ( temp 4-component vector of uint)
@@ -373,7 +373,7 @@ local_size = (1, 1, 1)
 0:21      all ( temp bool)
 0:21        Convert float to bool ( temp bool)
 0:21          'inF0' ( in float)
-0:24      AtomicAdd ( temp void)
+0:24      AtomicAdd ( temp uint)
 0:24        'gs_ua' ( shared uint)
 0:24        'gs_ub' ( shared uint)
 0:25      move second child to first child ( temp uint)
@@ -381,7 +381,7 @@ local_size = (1, 1, 1)
 0:25        AtomicAdd ( temp uint)
 0:25          'gs_ua' ( shared uint)
 0:25          'gs_ub' ( shared uint)
-0:26      AtomicAnd ( temp void)
+0:26      AtomicAnd ( temp uint)
 0:26        'gs_ua' ( shared uint)
 0:26        'gs_ub' ( shared uint)
 0:27      move second child to first child ( temp uint)
@@ -400,7 +400,7 @@ local_size = (1, 1, 1)
 0:29        AtomicExchange ( temp uint)
 0:29          'gs_ua' ( shared uint)
 0:29          'gs_ub' ( shared uint)
-0:30      AtomicMax ( temp void)
+0:30      AtomicMax ( temp uint)
 0:30        'gs_ua' ( shared uint)
 0:30        'gs_ub' ( shared uint)
 0:31      move second child to first child ( temp uint)
@@ -408,7 +408,7 @@ local_size = (1, 1, 1)
 0:31        AtomicMax ( temp uint)
 0:31          'gs_ua' ( shared uint)
 0:31          'gs_ub' ( shared uint)
-0:32      AtomicMin ( temp void)
+0:32      AtomicMin ( temp uint)
 0:32        'gs_ua' ( shared uint)
 0:32        'gs_ub' ( shared uint)
 0:33      move second child to first child ( temp uint)
@@ -416,7 +416,7 @@ local_size = (1, 1, 1)
 0:33        AtomicMin ( temp uint)
 0:33          'gs_ua' ( shared uint)
 0:33          'gs_ub' ( shared uint)
-0:34      AtomicOr ( temp void)
+0:34      AtomicOr ( temp uint)
 0:34        'gs_ua' ( shared uint)
 0:34        'gs_ub' ( shared uint)
 0:35      move second child to first child ( temp uint)
@@ -424,7 +424,7 @@ local_size = (1, 1, 1)
 0:35        AtomicOr ( temp uint)
 0:35          'gs_ua' ( shared uint)
 0:35          'gs_ub' ( shared uint)
-0:36      AtomicXor ( temp void)
+0:36      AtomicXor ( temp uint)
 0:36        'gs_ua' ( shared uint)
 0:36        'gs_ub' ( shared uint)
 0:37      move second child to first child ( temp uint)
@@ -455,7 +455,7 @@ local_size = (1, 1, 1)
 0:55      all ( temp bool)
 0:55        Convert float to bool ( temp 2-component vector of bool)
 0:55          'inF0' ( in 2-component vector of float)
-0:58      AtomicAdd ( temp void)
+0:58      AtomicAdd ( temp 2-component vector of uint)
 0:58        'gs_ua2' ( shared 2-component vector of uint)
 0:58        'gs_ub2' ( shared 2-component vector of uint)
 0:59      move second child to first child ( temp 2-component vector of uint)
@@ -463,7 +463,7 @@ local_size = (1, 1, 1)
 0:59        AtomicAdd ( temp 2-component vector of uint)
 0:59          'gs_ua2' ( shared 2-component vector of uint)
 0:59          'gs_ub2' ( shared 2-component vector of uint)
-0:60      AtomicAnd ( temp void)
+0:60      AtomicAnd ( temp 2-component vector of uint)
 0:60        'gs_ua2' ( shared 2-component vector of uint)
 0:60        'gs_ub2' ( shared 2-component vector of uint)
 0:61      move second child to first child ( temp 2-component vector of uint)
@@ -482,7 +482,7 @@ local_size = (1, 1, 1)
 0:63        AtomicExchange ( temp 2-component vector of uint)
 0:63          'gs_ua2' ( shared 2-component vector of uint)
 0:63          'gs_ub2' ( shared 2-component vector of uint)
-0:64      AtomicMax ( temp void)
+0:64      AtomicMax ( temp 2-component vector of uint)
 0:64        'gs_ua2' ( shared 2-component vector of uint)
 0:64        'gs_ub2' ( shared 2-component vector of uint)
 0:65      move second child to first child ( temp 2-component vector of uint)
@@ -490,7 +490,7 @@ local_size = (1, 1, 1)
 0:65        AtomicMax ( temp 2-component vector of uint)
 0:65          'gs_ua2' ( shared 2-component vector of uint)
 0:65          'gs_ub2' ( shared 2-component vector of uint)
-0:66      AtomicMin ( temp void)
+0:66      AtomicMin ( temp 2-component vector of uint)
 0:66        'gs_ua2' ( shared 2-component vector of uint)
 0:66        'gs_ub2' ( shared 2-component vector of uint)
 0:67      move second child to first child ( temp 2-component vector of uint)
@@ -498,7 +498,7 @@ local_size = (1, 1, 1)
 0:67        AtomicMin ( temp 2-component vector of uint)
 0:67          'gs_ua2' ( shared 2-component vector of uint)
 0:67          'gs_ub2' ( shared 2-component vector of uint)
-0:68      AtomicOr ( temp void)
+0:68      AtomicOr ( temp 2-component vector of uint)
 0:68        'gs_ua2' ( shared 2-component vector of uint)
 0:68        'gs_ub2' ( shared 2-component vector of uint)
 0:69      move second child to first child ( temp 2-component vector of uint)
@@ -506,7 +506,7 @@ local_size = (1, 1, 1)
 0:69        AtomicOr ( temp 2-component vector of uint)
 0:69          'gs_ua2' ( shared 2-component vector of uint)
 0:69          'gs_ub2' ( shared 2-component vector of uint)
-0:70      AtomicXor ( temp void)
+0:70      AtomicXor ( temp 2-component vector of uint)
 0:70        'gs_ua2' ( shared 2-component vector of uint)
 0:70        'gs_ub2' ( shared 2-component vector of uint)
 0:71      move second child to first child ( temp 2-component vector of uint)
@@ -529,7 +529,7 @@ local_size = (1, 1, 1)
 0:82      all ( temp bool)
 0:82        Convert float to bool ( temp 3-component vector of bool)
 0:82          'inF0' ( in 3-component vector of float)
-0:85      AtomicAdd ( temp void)
+0:85      AtomicAdd ( temp 3-component vector of uint)
 0:85        'gs_ua3' ( shared 3-component vector of uint)
 0:85        'gs_ub3' ( shared 3-component vector of uint)
 0:86      move second child to first child ( temp 3-component vector of uint)
@@ -537,7 +537,7 @@ local_size = (1, 1, 1)
 0:86        AtomicAdd ( temp 3-component vector of uint)
 0:86          'gs_ua3' ( shared 3-component vector of uint)
 0:86          'gs_ub3' ( shared 3-component vector of uint)
-0:87      AtomicAnd ( temp void)
+0:87      AtomicAnd ( temp 3-component vector of uint)
 0:87        'gs_ua3' ( shared 3-component vector of uint)
 0:87        'gs_ub3' ( shared 3-component vector of uint)
 0:88      move second child to first child ( temp 3-component vector of uint)
@@ -556,7 +556,7 @@ local_size = (1, 1, 1)
 0:90        AtomicExchange ( temp 3-component vector of uint)
 0:90          'gs_ua3' ( shared 3-component vector of uint)
 0:90          'gs_ub3' ( shared 3-component vector of uint)
-0:91      AtomicMax ( temp void)
+0:91      AtomicMax ( temp 3-component vector of uint)
 0:91        'gs_ua3' ( shared 3-component vector of uint)
 0:91        'gs_ub3' ( shared 3-component vector of uint)
 0:92      move second child to first child ( temp 3-component vector of uint)
@@ -564,7 +564,7 @@ local_size = (1, 1, 1)
 0:92        AtomicMax ( temp 3-component vector of uint)
 0:92          'gs_ua3' ( shared 3-component vector of uint)
 0:92          'gs_ub3' ( shared 3-component vector of uint)
-0:93      AtomicMin ( temp void)
+0:93      AtomicMin ( temp 3-component vector of uint)
 0:93        'gs_ua3' ( shared 3-component vector of uint)
 0:93        'gs_ub3' ( shared 3-component vector of uint)
 0:94      move second child to first child ( temp 3-component vector of uint)
@@ -572,7 +572,7 @@ local_size = (1, 1, 1)
 0:94        AtomicMin ( temp 3-component vector of uint)
 0:94          'gs_ua3' ( shared 3-component vector of uint)
 0:94          'gs_ub3' ( shared 3-component vector of uint)
-0:95      AtomicOr ( temp void)
+0:95      AtomicOr ( temp 3-component vector of uint)
 0:95        'gs_ua3' ( shared 3-component vector of uint)
 0:95        'gs_ub3' ( shared 3-component vector of uint)
 0:96      move second child to first child ( temp 3-component vector of uint)
@@ -580,7 +580,7 @@ local_size = (1, 1, 1)
 0:96        AtomicOr ( temp 3-component vector of uint)
 0:96          'gs_ua3' ( shared 3-component vector of uint)
 0:96          'gs_ub3' ( shared 3-component vector of uint)
-0:97      AtomicXor ( temp void)
+0:97      AtomicXor ( temp 3-component vector of uint)
 0:97        'gs_ua3' ( shared 3-component vector of uint)
 0:97        'gs_ub3' ( shared 3-component vector of uint)
 0:98      move second child to first child ( temp 3-component vector of uint)
@@ -604,7 +604,7 @@ local_size = (1, 1, 1)
 0:109      all ( temp bool)
 0:109        Convert float to bool ( temp 4-component vector of bool)
 0:109          'inF0' ( in 4-component vector of float)
-0:112      AtomicAdd ( temp void)
+0:112      AtomicAdd ( temp 4-component vector of uint)
 0:112        'gs_ua4' ( shared 4-component vector of uint)
 0:112        'gs_ub4' ( shared 4-component vector of uint)
 0:113      move second child to first child ( temp 4-component vector of uint)
@@ -612,7 +612,7 @@ local_size = (1, 1, 1)
 0:113        AtomicAdd ( temp 4-component vector of uint)
 0:113          'gs_ua4' ( shared 4-component vector of uint)
 0:113          'gs_ub4' ( shared 4-component vector of uint)
-0:114      AtomicAnd ( temp void)
+0:114      AtomicAnd ( temp 4-component vector of uint)
 0:114        'gs_ua4' ( shared 4-component vector of uint)
 0:114        'gs_ub4' ( shared 4-component vector of uint)
 0:115      move second child to first child ( temp 4-component vector of uint)
@@ -631,7 +631,7 @@ local_size = (1, 1, 1)
 0:117        AtomicExchange ( temp 4-component vector of uint)
 0:117          'gs_ua4' ( shared 4-component vector of uint)
 0:117          'gs_ub4' ( shared 4-component vector of uint)
-0:118      AtomicMax ( temp void)
+0:118      AtomicMax ( temp 4-component vector of uint)
 0:118        'gs_ua4' ( shared 4-component vector of uint)
 0:118        'gs_ub4' ( shared 4-component vector of uint)
 0:119      move second child to first child ( temp 4-component vector of uint)
@@ -639,7 +639,7 @@ local_size = (1, 1, 1)
 0:119        AtomicMax ( temp 4-component vector of uint)
 0:119          'gs_ua4' ( shared 4-component vector of uint)
 0:119          'gs_ub4' ( shared 4-component vector of uint)
-0:120      AtomicMin ( temp void)
+0:120      AtomicMin ( temp 4-component vector of uint)
 0:120        'gs_ua4' ( shared 4-component vector of uint)
 0:120        'gs_ub4' ( shared 4-component vector of uint)
 0:121      move second child to first child ( temp 4-component vector of uint)
@@ -647,7 +647,7 @@ local_size = (1, 1, 1)
 0:121        AtomicMin ( temp 4-component vector of uint)
 0:121          'gs_ua4' ( shared 4-component vector of uint)
 0:121          'gs_ub4' ( shared 4-component vector of uint)
-0:122      AtomicOr ( temp void)
+0:122      AtomicOr ( temp 4-component vector of uint)
 0:122        'gs_ua4' ( shared 4-component vector of uint)
 0:122        'gs_ub4' ( shared 4-component vector of uint)
 0:123      move second child to first child ( temp 4-component vector of uint)
@@ -655,7 +655,7 @@ local_size = (1, 1, 1)
 0:123        AtomicOr ( temp 4-component vector of uint)
 0:123          'gs_ua4' ( shared 4-component vector of uint)
 0:123          'gs_ub4' ( shared 4-component vector of uint)
-0:124      AtomicXor ( temp void)
+0:124      AtomicXor ( temp 4-component vector of uint)
 0:124        'gs_ua4' ( shared 4-component vector of uint)
 0:124        'gs_ub4' ( shared 4-component vector of uint)
 0:125      move second child to first child ( temp 4-component vector of uint)
@@ -905,12 +905,12 @@ local_size = (1, 1, 1)
               63:    61(bool) FOrdNotEqual 60 62
               64:    61(bool) All 63
               68:      8(int) Load 67(gs_ub)
-              71:           2 AtomicIAdd 66(gs_ua) 69 70 68
+              71:      8(int) AtomicIAdd 66(gs_ua) 69 70 68
               73:      8(int) Load 67(gs_ub)
               74:      8(int) AtomicIAdd 66(gs_ua) 69 70 73
                               Store 72(out_u1) 74
               75:      8(int) Load 67(gs_ub)
-              76:           2 AtomicAnd 66(gs_ua) 69 70 75
+              76:      8(int) AtomicAnd 66(gs_ua) 69 70 75
               77:      8(int) Load 67(gs_ub)
               78:      8(int) AtomicAnd 66(gs_ua) 69 70 77
                               Store 72(out_u1) 78
@@ -922,22 +922,22 @@ local_size = (1, 1, 1)
               84:      8(int) AtomicExchange 66(gs_ua) 69 70 83
                               Store 72(out_u1) 84
               85:      8(int) Load 67(gs_ub)
-              86:           2 AtomicSMax 66(gs_ua) 69 70 85
+              86:      8(int) AtomicUMax 66(gs_ua) 69 70 85
               87:      8(int) Load 67(gs_ub)
               88:      8(int) AtomicUMax 66(gs_ua) 69 70 87
                               Store 72(out_u1) 88
               89:      8(int) Load 67(gs_ub)
-              90:           2 AtomicSMin 66(gs_ua) 69 70 89
+              90:      8(int) AtomicUMin 66(gs_ua) 69 70 89
               91:      8(int) Load 67(gs_ub)
               92:      8(int) AtomicUMin 66(gs_ua) 69 70 91
                               Store 72(out_u1) 92
               93:      8(int) Load 67(gs_ub)
-              94:           2 AtomicOr 66(gs_ua) 69 70 93
+              94:      8(int) AtomicOr 66(gs_ua) 69 70 93
               95:      8(int) Load 67(gs_ub)
               96:      8(int) AtomicOr 66(gs_ua) 69 70 95
                               Store 72(out_u1) 96
               97:      8(int) Load 67(gs_ub)
-              98:           2 AtomicXor 66(gs_ua) 69 70 97
+              98:      8(int) AtomicXor 66(gs_ua) 69 70 97
               99:      8(int) Load 67(gs_ub)
              100:      8(int) AtomicXor 66(gs_ua) 69 70 99
                               Store 72(out_u1) 100
@@ -962,12 +962,12 @@ local_size = (1, 1, 1)
              108:  106(bvec2) FOrdNotEqual 105 107
              109:    61(bool) All 108
              113:   26(ivec2) Load 112(gs_ub2)
-             114:           2 AtomicIAdd 111(gs_ua2) 69 70 113
+             114:   26(ivec2) AtomicIAdd 111(gs_ua2) 69 70 113
              116:   26(ivec2) Load 112(gs_ub2)
              117:   26(ivec2) AtomicIAdd 111(gs_ua2) 69 70 116
                               Store 115(out_u2) 117
              118:   26(ivec2) Load 112(gs_ub2)
-             119:           2 AtomicAnd 111(gs_ua2) 69 70 118
+             119:   26(ivec2) AtomicAnd 111(gs_ua2) 69 70 118
              120:   26(ivec2) Load 112(gs_ub2)
              121:   26(ivec2) AtomicAnd 111(gs_ua2) 69 70 120
                               Store 115(out_u2) 121
@@ -979,22 +979,22 @@ local_size = (1, 1, 1)
              127:   26(ivec2) AtomicExchange 111(gs_ua2) 69 70 126
                               Store 115(out_u2) 127
              128:   26(ivec2) Load 112(gs_ub2)
-             129:           2 AtomicSMax 111(gs_ua2) 69 70 128
+             129:   26(ivec2) AtomicUMax 111(gs_ua2) 69 70 128
              130:   26(ivec2) Load 112(gs_ub2)
              131:   26(ivec2) AtomicUMax 111(gs_ua2) 69 70 130
                               Store 115(out_u2) 131
              132:   26(ivec2) Load 112(gs_ub2)
-             133:           2 AtomicSMin 111(gs_ua2) 69 70 132
+             133:   26(ivec2) AtomicUMin 111(gs_ua2) 69 70 132
              134:   26(ivec2) Load 112(gs_ub2)
              135:   26(ivec2) AtomicUMin 111(gs_ua2) 69 70 134
                               Store 115(out_u2) 135
              136:   26(ivec2) Load 112(gs_ub2)
-             137:           2 AtomicOr 111(gs_ua2) 69 70 136
+             137:   26(ivec2) AtomicOr 111(gs_ua2) 69 70 136
              138:   26(ivec2) Load 112(gs_ub2)
              139:   26(ivec2) AtomicOr 111(gs_ua2) 69 70 138
                               Store 115(out_u2) 139
              140:   26(ivec2) Load 112(gs_ub2)
-             141:           2 AtomicXor 111(gs_ua2) 69 70 140
+             141:   26(ivec2) AtomicXor 111(gs_ua2) 69 70 140
              142:   26(ivec2) Load 112(gs_ub2)
              143:   26(ivec2) AtomicXor 111(gs_ua2) 69 70 142
                               Store 115(out_u2) 143
@@ -1012,12 +1012,12 @@ local_size = (1, 1, 1)
              152:  150(bvec3) FOrdNotEqual 149 151
              153:    61(bool) All 152
              157:   38(ivec3) Load 156(gs_ub3)
-             158:           2 AtomicIAdd 155(gs_ua3) 69 70 157
+             158:   38(ivec3) AtomicIAdd 155(gs_ua3) 69 70 157
              160:   38(ivec3) Load 156(gs_ub3)
              161:   38(ivec3) AtomicIAdd 155(gs_ua3) 69 70 160
                               Store 159(out_u3) 161
              162:   38(ivec3) Load 156(gs_ub3)
-             163:           2 AtomicAnd 155(gs_ua3) 69 70 162
+             163:   38(ivec3) AtomicAnd 155(gs_ua3) 69 70 162
              164:   38(ivec3) Load 156(gs_ub3)
              165:   38(ivec3) AtomicAnd 155(gs_ua3) 69 70 164
                               Store 159(out_u3) 165
@@ -1029,22 +1029,22 @@ local_size = (1, 1, 1)
              171:   38(ivec3) AtomicExchange 155(gs_ua3) 69 70 170
                               Store 159(out_u3) 171
              172:   38(ivec3) Load 156(gs_ub3)
-             173:           2 AtomicSMax 155(gs_ua3) 69 70 172
+             173:   38(ivec3) AtomicUMax 155(gs_ua3) 69 70 172
              174:   38(ivec3) Load 156(gs_ub3)
              175:   38(ivec3) AtomicUMax 155(gs_ua3) 69 70 174
                               Store 159(out_u3) 175
              176:   38(ivec3) Load 156(gs_ub3)
-             177:           2 AtomicSMin 155(gs_ua3) 69 70 176
+             177:   38(ivec3) AtomicUMin 155(gs_ua3) 69 70 176
              178:   38(ivec3) Load 156(gs_ub3)
              179:   38(ivec3) AtomicUMin 155(gs_ua3) 69 70 178
                               Store 159(out_u3) 179
              180:   38(ivec3) Load 156(gs_ub3)
-             181:           2 AtomicOr 155(gs_ua3) 69 70 180
+             181:   38(ivec3) AtomicOr 155(gs_ua3) 69 70 180
              182:   38(ivec3) Load 156(gs_ub3)
              183:   38(ivec3) AtomicOr 155(gs_ua3) 69 70 182
                               Store 159(out_u3) 183
              184:   38(ivec3) Load 156(gs_ub3)
-             185:           2 AtomicXor 155(gs_ua3) 69 70 184
+             185:   38(ivec3) AtomicXor 155(gs_ua3) 69 70 184
              186:   38(ivec3) Load 156(gs_ub3)
              187:   38(ivec3) AtomicXor 155(gs_ua3) 69 70 186
                               Store 159(out_u3) 187
@@ -1062,12 +1062,12 @@ local_size = (1, 1, 1)
              195:  193(bvec4) FOrdNotEqual 192 194
              196:    61(bool) All 195
              200:   50(ivec4) Load 199(gs_ub4)
-             201:           2 AtomicIAdd 198(gs_ua4) 69 70 200
+             201:   50(ivec4) AtomicIAdd 198(gs_ua4) 69 70 200
              203:   50(ivec4) Load 199(gs_ub4)
              204:   50(ivec4) AtomicIAdd 198(gs_ua4) 69 70 203
                               Store 202(out_u4) 204
              205:   50(ivec4) Load 199(gs_ub4)
-             206:           2 AtomicAnd 198(gs_ua4) 69 70 205
+             206:   50(ivec4) AtomicAnd 198(gs_ua4) 69 70 205
              207:   50(ivec4) Load 199(gs_ub4)
              208:   50(ivec4) AtomicAnd 198(gs_ua4) 69 70 207
                               Store 202(out_u4) 208
@@ -1079,22 +1079,22 @@ local_size = (1, 1, 1)
              214:   50(ivec4) AtomicExchange 198(gs_ua4) 69 70 213
                               Store 202(out_u4) 214
              215:   50(ivec4) Load 199(gs_ub4)
-             216:           2 AtomicSMax 198(gs_ua4) 69 70 215
+             216:   50(ivec4) AtomicUMax 198(gs_ua4) 69 70 215
              217:   50(ivec4) Load 199(gs_ub4)
              218:   50(ivec4) AtomicUMax 198(gs_ua4) 69 70 217
                               Store 202(out_u4) 218
              219:   50(ivec4) Load 199(gs_ub4)
-             220:           2 AtomicSMin 198(gs_ua4) 69 70 219
+             220:   50(ivec4) AtomicUMin 198(gs_ua4) 69 70 219
              221:   50(ivec4) Load 199(gs_ub4)
              222:   50(ivec4) AtomicUMin 198(gs_ua4) 69 70 221
                               Store 202(out_u4) 222
              223:   50(ivec4) Load 199(gs_ub4)
-             224:           2 AtomicOr 198(gs_ua4) 69 70 223
+             224:   50(ivec4) AtomicOr 198(gs_ua4) 69 70 223
              225:   50(ivec4) Load 199(gs_ub4)
              226:   50(ivec4) AtomicOr 198(gs_ua4) 69 70 225
                               Store 202(out_u4) 226
              227:   50(ivec4) Load 199(gs_ub4)
-             228:           2 AtomicXor 198(gs_ua4) 69 70 227
+             228:   50(ivec4) AtomicXor 198(gs_ua4) 69 70 227
              229:   50(ivec4) Load 199(gs_ub4)
              230:   50(ivec4) AtomicXor 198(gs_ua4) 69 70 229
                               Store 202(out_u4) 230

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.load.2dms.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.load.2dms.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:28  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:28    Function Parameters: 
@@ -181,6 +182,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:28  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:28    Function Parameters: 
@@ -365,6 +367,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 120 124
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.load.array.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.load.array.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:48  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:48    Function Parameters: 
@@ -196,6 +197,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:48  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:48    Function Parameters: 
@@ -396,6 +398,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 104 108
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.load.basic.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.load.basic.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:48  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:48    Function Parameters: 
@@ -247,6 +248,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:48  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:48    Function Parameters: 
@@ -498,6 +500,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 133 137
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.load.buffer.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.load.buffer.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:24  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:24    Function Parameters: 
@@ -85,6 +86,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:24  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:24    Function Parameters: 
@@ -173,6 +175,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 64 68
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.load.buffer.float.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.load.buffer.float.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:24  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:24    Function Parameters: 
@@ -88,6 +89,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:24  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:24    Function Parameters: 
@@ -179,6 +181,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 67 71
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.load.offset.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.load.offset.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:48  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:48    Function Parameters: 
@@ -283,6 +284,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:48  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:48    Function Parameters: 
@@ -571,6 +573,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 155 159
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.load.offsetarray.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.load.offsetarray.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:48  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:48    Function Parameters: 
@@ -220,6 +221,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:48  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:48    Function Parameters: 
@@ -445,6 +447,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 119 123
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.load.rwtexture.array.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.load.rwtexture.array.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:40  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:40    Function Parameters: 
@@ -106,6 +107,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:40  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:40    Function Parameters: 
@@ -215,6 +217,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 82 86
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.load.rwtexture.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.load.rwtexture.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:40  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:40    Function Parameters: 
@@ -124,6 +125,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:40  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:40    Function Parameters: 
@@ -251,6 +253,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 104 108
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 23 - 24
3rdparty/glslang/Test/baseResults/hlsl.noSemantic.functionality1.comp.out

@@ -1,7 +1,7 @@
 hlsl.noSemantic.functionality1.comp
 // Module Version 10000
 // Generated by (magic number): 80006
-// Id's are bound by 31
+// Id's are bound by 30
 
                               Capability Shader
                               Extension  "SPV_GOOGLE_hlsl_functionality1"
@@ -15,18 +15,18 @@ hlsl.noSemantic.functionality1.comp
                               Name 11  "Buf"
                               MemberName 11(Buf) 0  "@data"
                               Name 13  "Buf"
-                              Name 16  "Buf@count"
-                              MemberName 16(Buf@count) 0  "@count"
-                              Name 18  "Buf@count"
+                              Name 17  "Buf@count"
+                              MemberName 17(Buf@count) 0  "@count"
+                              Name 19  "Buf@count"
                               Decorate 10 ArrayStride 16
                               MemberDecorate 11(Buf) 0 Offset 0
                               Decorate 11(Buf) BufferBlock
                               Decorate 13(Buf) DescriptorSet 0
                               Decorate 13(Buf) Binding 0
-                              MemberDecorate 16(Buf@count) 0 Offset 0
-                              Decorate 16(Buf@count) BufferBlock
-                              Decorate 18(Buf@count) DescriptorSet 0
-                              DecorateId 13(Buf) DecorationHlslCounterBufferGOOGLE 18(Buf@count)
+                              MemberDecorate 17(Buf@count) 0 Offset 0
+                              Decorate 17(Buf@count) BufferBlock
+                              Decorate 19(Buf@count) DescriptorSet 0
+                              DecorateId 13(Buf) DecorationHlslCounterBufferGOOGLE 19(Buf@count)
                2:             TypeVoid
                3:             TypeFunction 2
                8:             TypeFloat 32
@@ -37,27 +37,26 @@ hlsl.noSemantic.functionality1.comp
          13(Buf):     12(ptr) Variable Uniform
               14:             TypeInt 32 1
               15:     14(int) Constant 0
-   16(Buf@count):             TypeStruct 14(int)
-              17:             TypePointer Uniform 16(Buf@count)
-   18(Buf@count):     17(ptr) Variable Uniform
-              19:             TypePointer Uniform 14(int)
-              21:     14(int) Constant 1
-              22:             TypeInt 32 0
-              23:     22(int) Constant 1
-              24:     22(int) Constant 0
-              26:    8(float) Constant 1065353216
-              27:    9(fvec4) ConstantComposite 26 26 26 26
-              28:             TypePointer Uniform 9(fvec4)
+              16:             TypeInt 32 0
+   17(Buf@count):             TypeStruct 16(int)
+              18:             TypePointer Uniform 17(Buf@count)
+   19(Buf@count):     18(ptr) Variable Uniform
+              20:             TypePointer Uniform 16(int)
+              22:     16(int) Constant 1
+              23:     16(int) Constant 0
+              25:    8(float) Constant 1065353216
+              26:    9(fvec4) ConstantComposite 25 25 25 25
+              27:             TypePointer Uniform 9(fvec4)
          4(main):           2 Function None 3
                5:             Label
-              30:           2 FunctionCall 6(@main()
+              29:           2 FunctionCall 6(@main()
                               Return
                               FunctionEnd
        6(@main():           2 Function None 3
                7:             Label
-              20:     19(ptr) AccessChain 18(Buf@count) 15
-              25:     22(int) AtomicIAdd 20 23 24 21
-              29:     28(ptr) AccessChain 13(Buf) 15 25
-                              Store 29 27
+              21:     20(ptr) AccessChain 19(Buf@count) 15
+              24:     16(int) AtomicIAdd 21 22 23 22
+              28:     27(ptr) AccessChain 13(Buf) 15 24
+                              Store 28 26
                               Return
                               FunctionEnd

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.pp.line.frag.out

@@ -1,6 +1,7 @@
 hlsl.pp.line.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:4  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:4    Function Parameters: 
@@ -62,6 +63,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:4  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:4    Function Parameters: 
@@ -126,6 +128,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 35 39
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.sample.array.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.sample.array.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:24  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:24    Function Parameters: 
@@ -163,6 +164,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:24  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:24    Function Parameters: 
@@ -330,6 +332,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 138 142
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.sample.basic.dx10.frag.out

@@ -3,6 +3,7 @@ WARNING: 0:4: 'immediate sampler state' : unimplemented
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:53  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:53    Function Parameters: 
@@ -278,6 +279,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:53  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:53    Function Parameters: 
@@ -557,6 +559,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 188 192
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.sample.offset.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.sample.offset.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:28  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:28    Function Parameters: 
@@ -184,6 +185,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:28  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:28    Function Parameters: 
@@ -371,6 +373,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 144 148
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.sample.offsetarray.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.sample.offsetarray.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:20  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:20    Function Parameters: 
@@ -139,6 +140,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:20  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:20    Function Parameters: 
@@ -281,6 +283,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 110 114
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.samplebias.array.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.samplebias.array.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:24  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:24    Function Parameters: 
@@ -181,6 +182,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:24  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:24    Function Parameters: 
@@ -366,6 +368,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 138 142
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.samplebias.basic.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.samplebias.basic.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:28  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:28    Function Parameters: 
@@ -214,6 +215,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:28  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:28    Function Parameters: 
@@ -431,6 +433,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 162 166
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.samplebias.offset.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.samplebias.offset.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:28  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:28    Function Parameters: 
@@ -202,6 +203,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:28  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:28    Function Parameters: 
@@ -407,6 +409,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 144 148
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.samplebias.offsetarray.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.samplebias.offsetarray.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:20  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:20    Function Parameters: 
@@ -151,6 +152,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:20  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:20    Function Parameters: 
@@ -305,6 +307,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 110 114
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.samplecmp.array.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.samplecmp.array.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:38  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:38    Function Parameters: 
@@ -201,6 +202,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:38  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:38    Function Parameters: 
@@ -406,6 +408,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 166 170
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.samplecmp.basic.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.samplecmp.basic.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:38  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:38    Function Parameters: 
@@ -192,6 +193,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:38  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:38    Function Parameters: 
@@ -388,6 +390,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 155 159
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.samplecmp.offset.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.samplecmp.offset.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:38  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:38    Function Parameters: 
@@ -165,6 +166,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:38  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:38    Function Parameters: 
@@ -334,6 +336,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 115 119
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.samplecmp.offsetarray.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.samplecmp.offsetarray.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:38  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:38    Function Parameters: 
@@ -171,6 +172,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:38  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:38    Function Parameters: 
@@ -346,6 +348,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 126 130
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.samplecmplevelzero.array.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.samplecmplevelzero.array.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:38  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:38    Function Parameters: 
@@ -219,6 +220,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:38  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:38    Function Parameters: 
@@ -442,6 +444,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 167 171
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.samplecmplevelzero.basic.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.samplecmplevelzero.basic.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:38  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:38    Function Parameters: 
@@ -210,6 +211,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:38  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:38    Function Parameters: 
@@ -424,6 +426,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 156 160
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.samplecmplevelzero.offset.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.samplecmplevelzero.offset.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:38  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:38    Function Parameters: 
@@ -177,6 +178,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:38  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:38    Function Parameters: 
@@ -358,6 +360,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 116 120
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.samplecmplevelzero.offsetarray.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.samplecmplevelzero.offsetarray.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:38  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:38    Function Parameters: 
@@ -183,6 +184,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:38  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:38    Function Parameters: 
@@ -370,6 +372,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 127 131
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.samplegrad.array.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.samplegrad.array.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:24  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:24    Function Parameters: 
@@ -217,6 +218,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:24  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:24    Function Parameters: 
@@ -438,6 +440,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 132 136
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.samplegrad.basic.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.samplegrad.basic.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:28  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:28    Function Parameters: 
@@ -268,6 +269,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:28  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:28    Function Parameters: 
@@ -539,6 +541,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 167 171
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.samplegrad.offset.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.samplegrad.offset.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:28  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:28    Function Parameters: 
@@ -238,6 +239,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:28  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:28    Function Parameters: 
@@ -479,6 +481,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 149 153
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.samplegrad.offsetarray.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.samplegrad.offsetarray.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:24  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:24    Function Parameters: 
@@ -172,6 +173,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:24  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:24    Function Parameters: 
@@ -348,6 +350,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 103 107
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.samplelevel.array.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.samplelevel.array.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:24  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:24    Function Parameters: 
@@ -181,6 +182,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:24  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:24    Function Parameters: 
@@ -366,6 +368,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 139 143
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.samplelevel.basic.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.samplelevel.basic.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:29  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:29    Function Parameters: 
@@ -215,6 +216,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:29  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:29    Function Parameters: 
@@ -433,6 +435,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 163 167
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.samplelevel.offset.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.samplelevel.offset.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:28  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:28    Function Parameters: 
@@ -202,6 +203,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:28  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:28    Function Parameters: 
@@ -407,6 +409,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 145 149
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 3 - 0
3rdparty/glslang/Test/baseResults/hlsl.samplelevel.offsetarray.dx10.frag.out

@@ -1,6 +1,7 @@
 hlsl.samplelevel.offsetarray.dx10.frag
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:20  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:20    Function Parameters: 
@@ -151,6 +152,7 @@ Linked fragment stage:
 
 Shader version: 500
 gl_FragCoord origin is upper left
+using depth_any
 0:? Sequence
 0:20  Function Definition: @main( ( temp structure{ temp 4-component vector of float Color,  temp float Depth})
 0:20    Function Parameters: 
@@ -305,6 +307,7 @@ gl_FragCoord origin is upper left
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 111 115
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 1 - 0
3rdparty/glslang/Test/baseResults/hlsl.structIoFourWay.frag.out

@@ -171,6 +171,7 @@ using depth_greater
                               EntryPoint Fragment 4  "main" 22 27 31 36 45 48 51 55
                               ExecutionMode 4 OriginUpperLeft
                               ExecutionMode 4 DepthGreater
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "T"

+ 56 - 56
3rdparty/glslang/Test/baseResults/hlsl.structbuffer.append.fn.frag.out

@@ -5,9 +5,9 @@ gl_FragCoord origin is upper left
 0:8  Function Definition: Fn2(block--vf4[0]1;block--vf4[0]1; ( temp 4-component vector of float)
 0:8    Function Parameters: 
 0:8      'arg_a' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of float @data})
-0:8      'arg_a@count' ( buffer block{layout( row_major std430) buffer int @count})
+0:8      'arg_a@count' ( buffer block{layout( row_major std430) buffer uint @count})
 0:8      'arg_c' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of float @data})
-0:8      'arg_c@count' ( buffer block{layout( row_major std430) buffer int @count})
+0:8      'arg_c@count' ( buffer block{layout( row_major std430) buffer uint @count})
 0:?     Sequence
 0:9      move second child to first child ( temp 4-component vector of float)
 0:9        indirect index ( buffer 4-component vector of float)
@@ -16,12 +16,12 @@ gl_FragCoord origin is upper left
 0:9            Constant:
 0:9              0 (const uint)
 0:9          AtomicAdd ( temp uint)
-0:9            @count: direct index for structure ( temp int)
-0:9              'arg_a@count' ( buffer block{layout( row_major std430) buffer int @count})
+0:9            @count: direct index for structure ( temp uint)
+0:9              'arg_a@count' ( buffer block{layout( row_major std430) buffer uint @count})
 0:9              Constant:
 0:9                0 (const int)
 0:9            Constant:
-0:9              1 (const int)
+0:9              1 (const uint)
 0:?         Constant:
 0:?           1.000000
 0:?           2.000000
@@ -35,12 +35,12 @@ gl_FragCoord origin is upper left
 0:10              0 (const uint)
 0:10          add ( temp uint)
 0:10            AtomicAdd ( temp uint)
-0:10              @count: direct index for structure ( temp int)
-0:10                'arg_c@count' ( buffer block{layout( row_major std430) buffer int @count})
+0:10              @count: direct index for structure ( temp uint)
+0:10                'arg_c@count' ( buffer block{layout( row_major std430) buffer uint @count})
 0:10                Constant:
 0:10                  0 (const int)
 0:10              Constant:
-0:10                -1 (const int)
+0:10                4294967295 (const uint)
 0:10            Constant:
 0:10              -1 (const int)
 0:19  Function Definition: @main(u1; ( temp 4-component vector of float)
@@ -50,9 +50,9 @@ gl_FragCoord origin is upper left
 0:22      Branch: Return with expression
 0:22        Function Call: Fn2(block--vf4[0]1;block--vf4[0]1; ( temp 4-component vector of float)
 0:22          'sbuf_a' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of float @data})
-0:22          'sbuf_a@count' ( buffer block{layout( row_major std430) buffer int @count})
+0:22          'sbuf_a@count' ( buffer block{layout( row_major std430) buffer uint @count})
 0:22          'sbuf_c' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of float @data})
-0:22          'sbuf_c@count' ( buffer block{layout( row_major std430) buffer int @count})
+0:22          'sbuf_c@count' ( buffer block{layout( row_major std430) buffer uint @count})
 0:19  Function Definition: main( ( temp void)
 0:19    Function Parameters: 
 0:?     Sequence
@@ -65,9 +65,9 @@ gl_FragCoord origin is upper left
 0:?           'pos' ( temp uint)
 0:?   Linker Objects
 0:?     'sbuf_a' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of float @data})
-0:?     'sbuf_a@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer int @count})
+0:?     'sbuf_a@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer uint @count})
 0:?     'sbuf_c' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of float @data})
-0:?     'sbuf_c@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer int @count})
+0:?     'sbuf_c@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer uint @count})
 0:?     'sbuf_unused' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of float @data})
 0:?     '@entryPointOutput' (layout( location=0) out 4-component vector of float)
 0:?     'pos' (layout( location=0) flat in uint)
@@ -82,9 +82,9 @@ gl_FragCoord origin is upper left
 0:8  Function Definition: Fn2(block--vf4[0]1;block--vf4[0]1; ( temp 4-component vector of float)
 0:8    Function Parameters: 
 0:8      'arg_a' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of float @data})
-0:8      'arg_a@count' ( buffer block{layout( row_major std430) buffer int @count})
+0:8      'arg_a@count' ( buffer block{layout( row_major std430) buffer uint @count})
 0:8      'arg_c' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of float @data})
-0:8      'arg_c@count' ( buffer block{layout( row_major std430) buffer int @count})
+0:8      'arg_c@count' ( buffer block{layout( row_major std430) buffer uint @count})
 0:?     Sequence
 0:9      move second child to first child ( temp 4-component vector of float)
 0:9        indirect index ( buffer 4-component vector of float)
@@ -93,12 +93,12 @@ gl_FragCoord origin is upper left
 0:9            Constant:
 0:9              0 (const uint)
 0:9          AtomicAdd ( temp uint)
-0:9            @count: direct index for structure ( temp int)
-0:9              'arg_a@count' ( buffer block{layout( row_major std430) buffer int @count})
+0:9            @count: direct index for structure ( temp uint)
+0:9              'arg_a@count' ( buffer block{layout( row_major std430) buffer uint @count})
 0:9              Constant:
 0:9                0 (const int)
 0:9            Constant:
-0:9              1 (const int)
+0:9              1 (const uint)
 0:?         Constant:
 0:?           1.000000
 0:?           2.000000
@@ -112,12 +112,12 @@ gl_FragCoord origin is upper left
 0:10              0 (const uint)
 0:10          add ( temp uint)
 0:10            AtomicAdd ( temp uint)
-0:10              @count: direct index for structure ( temp int)
-0:10                'arg_c@count' ( buffer block{layout( row_major std430) buffer int @count})
+0:10              @count: direct index for structure ( temp uint)
+0:10                'arg_c@count' ( buffer block{layout( row_major std430) buffer uint @count})
 0:10                Constant:
 0:10                  0 (const int)
 0:10              Constant:
-0:10                -1 (const int)
+0:10                4294967295 (const uint)
 0:10            Constant:
 0:10              -1 (const int)
 0:19  Function Definition: @main(u1; ( temp 4-component vector of float)
@@ -127,9 +127,9 @@ gl_FragCoord origin is upper left
 0:22      Branch: Return with expression
 0:22        Function Call: Fn2(block--vf4[0]1;block--vf4[0]1; ( temp 4-component vector of float)
 0:22          'sbuf_a' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of float @data})
-0:22          'sbuf_a@count' ( buffer block{layout( row_major std430) buffer int @count})
+0:22          'sbuf_a@count' ( buffer block{layout( row_major std430) buffer uint @count})
 0:22          'sbuf_c' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of float @data})
-0:22          'sbuf_c@count' ( buffer block{layout( row_major std430) buffer int @count})
+0:22          'sbuf_c@count' ( buffer block{layout( row_major std430) buffer uint @count})
 0:19  Function Definition: main( ( temp void)
 0:19    Function Parameters: 
 0:?     Sequence
@@ -142,9 +142,9 @@ gl_FragCoord origin is upper left
 0:?           'pos' ( temp uint)
 0:?   Linker Objects
 0:?     'sbuf_a' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of float @data})
-0:?     'sbuf_a@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer int @count})
+0:?     'sbuf_a@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer uint @count})
 0:?     'sbuf_c' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of float @data})
-0:?     'sbuf_c@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer int @count})
+0:?     'sbuf_c@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer uint @count})
 0:?     'sbuf_unused' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of float @data})
 0:?     '@entryPointOutput' (layout( location=0) out 4-component vector of float)
 0:?     'pos' (layout( location=0) flat in uint)
@@ -169,8 +169,8 @@ gl_FragCoord origin is upper left
                               Name 16  "arg_a@count"
                               Name 17  "arg_c"
                               Name 18  "arg_c@count"
-                              Name 25  "@main(u1;"
-                              Name 24  "pos"
+                              Name 24  "@main(u1;"
+                              Name 23  "pos"
                               Name 49  "sbuf_a"
                               Name 50  "sbuf_a@count"
                               Name 51  "sbuf_c"
@@ -207,30 +207,30 @@ gl_FragCoord origin is upper left
                8:             TypeRuntimeArray 7(fvec4)
                9:             TypeStruct 8
               10:             TypePointer Uniform 9(struct)
-              11:             TypeInt 32 1
+              11:             TypeInt 32 0
               12:             TypeStruct 11(int)
               13:             TypePointer Uniform 12(struct)
               14:             TypeFunction 7(fvec4) 10(ptr) 13(ptr) 10(ptr) 13(ptr)
-              21:             TypeInt 32 0
-              22:             TypePointer Function 21(int)
-              23:             TypeFunction 7(fvec4) 22(ptr)
-              27:     11(int) Constant 0
+              21:             TypePointer Function 11(int)
+              22:             TypeFunction 7(fvec4) 21(ptr)
+              26:             TypeInt 32 1
+              27:     26(int) Constant 0
               28:             TypePointer Uniform 11(int)
               30:     11(int) Constant 1
-              31:     21(int) Constant 1
-              32:     21(int) Constant 0
-              34:    6(float) Constant 1065353216
-              35:    6(float) Constant 1073741824
-              36:    6(float) Constant 1077936128
-              37:    6(float) Constant 1082130432
-              38:    7(fvec4) ConstantComposite 34 35 36 37
-              39:             TypePointer Uniform 7(fvec4)
-              42:     11(int) Constant 4294967295
+              31:     11(int) Constant 0
+              33:    6(float) Constant 1065353216
+              34:    6(float) Constant 1073741824
+              35:    6(float) Constant 1077936128
+              36:    6(float) Constant 1082130432
+              37:    7(fvec4) ConstantComposite 33 34 35 36
+              38:             TypePointer Uniform 7(fvec4)
+              41:     11(int) Constant 4294967295
+              43:     26(int) Constant 4294967295
       49(sbuf_a):     10(ptr) Variable Uniform
 50(sbuf_a@count):     13(ptr) Variable Uniform
       51(sbuf_c):     10(ptr) Variable Uniform
 52(sbuf_c@count):     13(ptr) Variable Uniform
-              57:             TypePointer Input 21(int)
+              57:             TypePointer Input 11(int)
          58(pos):     57(ptr) Variable Input
               60:             TypePointer Output 7(fvec4)
 61(@entryPointOutput):     60(ptr) Variable Output
@@ -241,13 +241,13 @@ gl_FragCoord origin is upper left
  69(sbuf_unused):     10(ptr) Variable Uniform
          4(main):           2 Function None 3
                5:             Label
-         56(pos):     22(ptr) Variable Function
-       62(param):     22(ptr) Variable Function
-              59:     21(int) Load 58(pos)
+         56(pos):     21(ptr) Variable Function
+       62(param):     21(ptr) Variable Function
+              59:     11(int) Load 58(pos)
                               Store 56(pos) 59
-              63:     21(int) Load 56(pos)
+              63:     11(int) Load 56(pos)
                               Store 62(param) 63
-              64:    7(fvec4) FunctionCall 25(@main(u1;) 62(param)
+              64:    7(fvec4) FunctionCall 24(@main(u1;) 62(param)
                               Store 61(@entryPointOutput) 64
                               Return
                               FunctionEnd
@@ -258,19 +258,19 @@ gl_FragCoord origin is upper left
  18(arg_c@count):     13(ptr) FunctionParameter
               20:             Label
               29:     28(ptr) AccessChain 16(arg_a@count) 27
-              33:     21(int) AtomicIAdd 29 31 32 30
-              40:     39(ptr) AccessChain 15(arg_a) 27 33
-                              Store 40 38
-              41:     28(ptr) AccessChain 18(arg_c@count) 27
-              43:     21(int) AtomicIAdd 41 31 32 42
-              44:     21(int) IAdd 43 42
-              45:     39(ptr) AccessChain 17(arg_c) 27 44
+              32:     11(int) AtomicIAdd 29 30 31 30
+              39:     38(ptr) AccessChain 15(arg_a) 27 32
+                              Store 39 37
+              40:     28(ptr) AccessChain 18(arg_c@count) 27
+              42:     11(int) AtomicIAdd 40 30 31 41
+              44:     11(int) IAdd 42 43
+              45:     38(ptr) AccessChain 17(arg_c) 27 44
               46:    7(fvec4) Load 45
                               ReturnValue 46
                               FunctionEnd
-   25(@main(u1;):    7(fvec4) Function None 23
-         24(pos):     22(ptr) FunctionParameter
-              26:             Label
+   24(@main(u1;):    7(fvec4) Function None 22
+         23(pos):     21(ptr) FunctionParameter
+              25:             Label
               53:    7(fvec4) FunctionCall 19(Fn2(block--vf4[0]1;block--vf4[0]1;) 49(sbuf_a) 50(sbuf_a@count) 51(sbuf_c) 52(sbuf_c@count)
                               ReturnValue 53
                               FunctionEnd

+ 41 - 41
3rdparty/glslang/Test/baseResults/hlsl.structbuffer.append.frag.out

@@ -13,12 +13,12 @@ gl_FragCoord origin is upper left
 0:8            Constant:
 0:8              0 (const uint)
 0:8          AtomicAdd ( temp uint)
-0:8            @count: direct index for structure ( temp int)
-0:8              'sbuf_a@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer int @count})
+0:8            @count: direct index for structure ( temp uint)
+0:8              'sbuf_a@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer uint @count})
 0:8              Constant:
 0:8                0 (const int)
 0:8            Constant:
-0:8              1 (const int)
+0:8              1 (const uint)
 0:?         Constant:
 0:?           1.000000
 0:?           2.000000
@@ -32,12 +32,12 @@ gl_FragCoord origin is upper left
 0:10              0 (const uint)
 0:10          add ( temp uint)
 0:10            AtomicAdd ( temp uint)
-0:10              @count: direct index for structure ( temp int)
-0:10                'sbuf_c@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer int @count})
+0:10              @count: direct index for structure ( temp uint)
+0:10                'sbuf_c@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer uint @count})
 0:10                Constant:
 0:10                  0 (const int)
 0:10              Constant:
-0:10                -1 (const int)
+0:10                4294967295 (const uint)
 0:10            Constant:
 0:10              -1 (const int)
 0:7  Function Definition: main( ( temp void)
@@ -52,9 +52,9 @@ gl_FragCoord origin is upper left
 0:?           'pos' ( temp uint)
 0:?   Linker Objects
 0:?     'sbuf_a' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of float @data})
-0:?     'sbuf_a@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer int @count})
+0:?     'sbuf_a@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer uint @count})
 0:?     'sbuf_c' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of float @data})
-0:?     'sbuf_c@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer int @count})
+0:?     'sbuf_c@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer uint @count})
 0:?     'sbuf_unused' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of float @data})
 0:?     '@entryPointOutput' (layout( location=0) out 4-component vector of float)
 0:?     'pos' (layout( location=0) flat in uint)
@@ -77,12 +77,12 @@ gl_FragCoord origin is upper left
 0:8            Constant:
 0:8              0 (const uint)
 0:8          AtomicAdd ( temp uint)
-0:8            @count: direct index for structure ( temp int)
-0:8              'sbuf_a@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer int @count})
+0:8            @count: direct index for structure ( temp uint)
+0:8              'sbuf_a@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer uint @count})
 0:8              Constant:
 0:8                0 (const int)
 0:8            Constant:
-0:8              1 (const int)
+0:8              1 (const uint)
 0:?         Constant:
 0:?           1.000000
 0:?           2.000000
@@ -96,12 +96,12 @@ gl_FragCoord origin is upper left
 0:10              0 (const uint)
 0:10          add ( temp uint)
 0:10            AtomicAdd ( temp uint)
-0:10              @count: direct index for structure ( temp int)
-0:10                'sbuf_c@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer int @count})
+0:10              @count: direct index for structure ( temp uint)
+0:10                'sbuf_c@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer uint @count})
 0:10                Constant:
 0:10                  0 (const int)
 0:10              Constant:
-0:10                -1 (const int)
+0:10                4294967295 (const uint)
 0:10            Constant:
 0:10              -1 (const int)
 0:7  Function Definition: main( ( temp void)
@@ -116,9 +116,9 @@ gl_FragCoord origin is upper left
 0:?           'pos' ( temp uint)
 0:?   Linker Objects
 0:?     'sbuf_a' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of float @data})
-0:?     'sbuf_a@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer int @count})
+0:?     'sbuf_a@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer uint @count})
 0:?     'sbuf_c' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of float @data})
-0:?     'sbuf_c@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer int @count})
+0:?     'sbuf_c@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer uint @count})
 0:?     'sbuf_unused' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of float @data})
 0:?     '@entryPointOutput' (layout( location=0) out 4-component vector of float)
 0:?     'pos' (layout( location=0) flat in uint)
@@ -142,8 +142,8 @@ gl_FragCoord origin is upper left
                               Name 20  "sbuf_a@count"
                               MemberName 20(sbuf_a@count) 0  "@count"
                               Name 22  "sbuf_a@count"
-                              Name 36  "sbuf_c"
-                              Name 37  "sbuf_c@count"
+                              Name 35  "sbuf_c"
+                              Name 36  "sbuf_c@count"
                               Name 46  "pos"
                               Name 48  "pos"
                               Name 51  "@entryPointOutput"
@@ -156,8 +156,8 @@ gl_FragCoord origin is upper left
                               MemberDecorate 20(sbuf_a@count) 0 Offset 0
                               Decorate 20(sbuf_a@count) BufferBlock
                               Decorate 22(sbuf_a@count) DescriptorSet 0
-                              Decorate 36(sbuf_c) DescriptorSet 0
-                              Decorate 37(sbuf_c@count) DescriptorSet 0
+                              Decorate 35(sbuf_c) DescriptorSet 0
+                              Decorate 36(sbuf_c@count) DescriptorSet 0
                               Decorate 48(pos) Flat
                               Decorate 48(pos) Location 0
                               Decorate 51(@entryPointOutput) Location 0
@@ -175,22 +175,22 @@ gl_FragCoord origin is upper left
       17(sbuf_a):     16(ptr) Variable Uniform
               18:             TypeInt 32 1
               19:     18(int) Constant 0
-20(sbuf_a@count):             TypeStruct 18(int)
+20(sbuf_a@count):             TypeStruct 6(int)
               21:             TypePointer Uniform 20(sbuf_a@count)
 22(sbuf_a@count):     21(ptr) Variable Uniform
-              23:             TypePointer Uniform 18(int)
-              25:     18(int) Constant 1
-              26:      6(int) Constant 1
-              27:      6(int) Constant 0
-              29:    8(float) Constant 1065353216
-              30:    8(float) Constant 1073741824
-              31:    8(float) Constant 1077936128
-              32:    8(float) Constant 1082130432
-              33:    9(fvec4) ConstantComposite 29 30 31 32
-              34:             TypePointer Uniform 9(fvec4)
-      36(sbuf_c):     16(ptr) Variable Uniform
-37(sbuf_c@count):     21(ptr) Variable Uniform
-              39:     18(int) Constant 4294967295
+              23:             TypePointer Uniform 6(int)
+              25:      6(int) Constant 1
+              26:      6(int) Constant 0
+              28:    8(float) Constant 1065353216
+              29:    8(float) Constant 1073741824
+              30:    8(float) Constant 1077936128
+              31:    8(float) Constant 1082130432
+              32:    9(fvec4) ConstantComposite 28 29 30 31
+              33:             TypePointer Uniform 9(fvec4)
+      35(sbuf_c):     16(ptr) Variable Uniform
+36(sbuf_c@count):     21(ptr) Variable Uniform
+              38:      6(int) Constant 4294967295
+              40:     18(int) Constant 4294967295
               47:             TypePointer Input 6(int)
          48(pos):     47(ptr) Variable Input
               50:             TypePointer Output 9(fvec4)
@@ -212,13 +212,13 @@ gl_FragCoord origin is upper left
          11(pos):      7(ptr) FunctionParameter
               13:             Label
               24:     23(ptr) AccessChain 22(sbuf_a@count) 19
-              28:      6(int) AtomicIAdd 24 26 27 25
-              35:     34(ptr) AccessChain 17(sbuf_a) 19 28
-                              Store 35 33
-              38:     23(ptr) AccessChain 37(sbuf_c@count) 19
-              40:      6(int) AtomicIAdd 38 26 27 39
-              41:      6(int) IAdd 40 39
-              42:     34(ptr) AccessChain 36(sbuf_c) 19 41
+              27:      6(int) AtomicIAdd 24 25 26 25
+              34:     33(ptr) AccessChain 17(sbuf_a) 19 27
+                              Store 34 32
+              37:     23(ptr) AccessChain 36(sbuf_c@count) 19
+              39:      6(int) AtomicIAdd 37 25 26 38
+              41:      6(int) IAdd 39 40
+              42:     33(ptr) AccessChain 35(sbuf_c) 19 41
               43:    9(fvec4) Load 42
                               ReturnValue 43
                               FunctionEnd

+ 18 - 18
3rdparty/glslang/Test/baseResults/hlsl.structbuffer.atomics.frag.out

@@ -6,7 +6,7 @@ gl_FragCoord origin is upper left
 0:5    Function Parameters: 
 0:5      'pos' ( in uint)
 0:?     Sequence
-0:8      AtomicAdd ( temp void)
+0:8      AtomicAdd ( temp uint)
 0:8        indirect index (layout( row_major std430) buffer uint)
 0:8          @data: direct index for structure (layout( row_major std430) buffer unsized 1-element array of uint)
 0:8            'sbuf' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of uint @data})
@@ -34,7 +34,7 @@ gl_FragCoord origin is upper left
 0:9                2 (const int)
 0:9          Constant:
 0:9            1 (const int)
-0:10      AtomicAnd ( temp void)
+0:10      AtomicAnd ( temp uint)
 0:10        indirect index (layout( row_major std430) buffer uint)
 0:10          @data: direct index for structure (layout( row_major std430) buffer unsized 1-element array of uint)
 0:10            'sbuf' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of uint @data})
@@ -95,7 +95,7 @@ gl_FragCoord origin is upper left
 0:14                2 (const int)
 0:14          Constant:
 0:14            1 (const int)
-0:15      AtomicMax ( temp void)
+0:15      AtomicMax ( temp uint)
 0:15        indirect index (layout( row_major std430) buffer uint)
 0:15          @data: direct index for structure (layout( row_major std430) buffer unsized 1-element array of uint)
 0:15            'sbuf' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of uint @data})
@@ -123,7 +123,7 @@ gl_FragCoord origin is upper left
 0:16                2 (const int)
 0:16          Constant:
 0:16            1 (const int)
-0:17      AtomicMin ( temp void)
+0:17      AtomicMin ( temp uint)
 0:17        indirect index (layout( row_major std430) buffer uint)
 0:17          @data: direct index for structure (layout( row_major std430) buffer unsized 1-element array of uint)
 0:17            'sbuf' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of uint @data})
@@ -151,7 +151,7 @@ gl_FragCoord origin is upper left
 0:18                2 (const int)
 0:18          Constant:
 0:18            1 (const int)
-0:19      AtomicOr ( temp void)
+0:19      AtomicOr ( temp uint)
 0:19        indirect index (layout( row_major std430) buffer uint)
 0:19          @data: direct index for structure (layout( row_major std430) buffer unsized 1-element array of uint)
 0:19            'sbuf' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of uint @data})
@@ -179,7 +179,7 @@ gl_FragCoord origin is upper left
 0:20                2 (const int)
 0:20          Constant:
 0:20            1 (const int)
-0:21      AtomicXor ( temp void)
+0:21      AtomicXor ( temp uint)
 0:21        indirect index (layout( row_major std430) buffer uint)
 0:21          @data: direct index for structure (layout( row_major std430) buffer unsized 1-element array of uint)
 0:21            'sbuf' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of uint @data})
@@ -245,7 +245,7 @@ gl_FragCoord origin is upper left
 0:5    Function Parameters: 
 0:5      'pos' ( in uint)
 0:?     Sequence
-0:8      AtomicAdd ( temp void)
+0:8      AtomicAdd ( temp uint)
 0:8        indirect index (layout( row_major std430) buffer uint)
 0:8          @data: direct index for structure (layout( row_major std430) buffer unsized 1-element array of uint)
 0:8            'sbuf' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of uint @data})
@@ -273,7 +273,7 @@ gl_FragCoord origin is upper left
 0:9                2 (const int)
 0:9          Constant:
 0:9            1 (const int)
-0:10      AtomicAnd ( temp void)
+0:10      AtomicAnd ( temp uint)
 0:10        indirect index (layout( row_major std430) buffer uint)
 0:10          @data: direct index for structure (layout( row_major std430) buffer unsized 1-element array of uint)
 0:10            'sbuf' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of uint @data})
@@ -334,7 +334,7 @@ gl_FragCoord origin is upper left
 0:14                2 (const int)
 0:14          Constant:
 0:14            1 (const int)
-0:15      AtomicMax ( temp void)
+0:15      AtomicMax ( temp uint)
 0:15        indirect index (layout( row_major std430) buffer uint)
 0:15          @data: direct index for structure (layout( row_major std430) buffer unsized 1-element array of uint)
 0:15            'sbuf' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of uint @data})
@@ -362,7 +362,7 @@ gl_FragCoord origin is upper left
 0:16                2 (const int)
 0:16          Constant:
 0:16            1 (const int)
-0:17      AtomicMin ( temp void)
+0:17      AtomicMin ( temp uint)
 0:17        indirect index (layout( row_major std430) buffer uint)
 0:17          @data: direct index for structure (layout( row_major std430) buffer unsized 1-element array of uint)
 0:17            'sbuf' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of uint @data})
@@ -390,7 +390,7 @@ gl_FragCoord origin is upper left
 0:18                2 (const int)
 0:18          Constant:
 0:18            1 (const int)
-0:19      AtomicOr ( temp void)
+0:19      AtomicOr ( temp uint)
 0:19        indirect index (layout( row_major std430) buffer uint)
 0:19          @data: direct index for structure (layout( row_major std430) buffer unsized 1-element array of uint)
 0:19            'sbuf' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of uint @data})
@@ -418,7 +418,7 @@ gl_FragCoord origin is upper left
 0:20                2 (const int)
 0:20          Constant:
 0:20            1 (const int)
-0:21      AtomicXor ( temp void)
+0:21      AtomicXor ( temp uint)
 0:21        indirect index (layout( row_major std430) buffer uint)
 0:21          @data: direct index for structure (layout( row_major std430) buffer unsized 1-element array of uint)
 0:21            'sbuf' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of uint @data})
@@ -542,14 +542,14 @@ gl_FragCoord origin is upper left
            29(u):      7(ptr) Variable Function
               22:     18(int) ShiftRightArithmetic 20 21
               24:     23(ptr) AccessChain 17(sbuf) 19 22
-              28:           2 AtomicIAdd 24 26 27 25
+              28:      6(int) AtomicIAdd 24 26 27 25
               30:     18(int) ShiftRightArithmetic 20 21
               31:     23(ptr) AccessChain 17(sbuf) 19 30
               32:      6(int) AtomicIAdd 31 26 27 25
                               Store 29(u) 32
               33:     18(int) ShiftRightArithmetic 20 21
               34:     23(ptr) AccessChain 17(sbuf) 19 33
-              35:           2 AtomicAnd 34 26 27 25
+              35:      6(int) AtomicAnd 34 26 27 25
               36:     18(int) ShiftRightArithmetic 20 21
               37:     23(ptr) AccessChain 17(sbuf) 19 36
               38:      6(int) AtomicAnd 37 26 27 25
@@ -565,28 +565,28 @@ gl_FragCoord origin is upper left
                               Store 29(u) 45
               46:     18(int) ShiftRightArithmetic 20 21
               47:     23(ptr) AccessChain 17(sbuf) 19 46
-              48:           2 AtomicSMax 47 26 27 25
+              48:      6(int) AtomicUMax 47 26 27 25
               49:     18(int) ShiftRightArithmetic 20 21
               50:     23(ptr) AccessChain 17(sbuf) 19 49
               51:      6(int) AtomicUMax 50 26 27 25
                               Store 29(u) 51
               52:     18(int) ShiftRightArithmetic 20 21
               53:     23(ptr) AccessChain 17(sbuf) 19 52
-              54:           2 AtomicSMin 53 26 27 25
+              54:      6(int) AtomicUMin 53 26 27 25
               55:     18(int) ShiftRightArithmetic 20 21
               56:     23(ptr) AccessChain 17(sbuf) 19 55
               57:      6(int) AtomicUMin 56 26 27 25
                               Store 29(u) 57
               58:     18(int) ShiftRightArithmetic 20 21
               59:     23(ptr) AccessChain 17(sbuf) 19 58
-              60:           2 AtomicOr 59 26 27 25
+              60:      6(int) AtomicOr 59 26 27 25
               61:     18(int) ShiftRightArithmetic 20 21
               62:     23(ptr) AccessChain 17(sbuf) 19 61
               63:      6(int) AtomicOr 62 26 27 25
                               Store 29(u) 63
               64:     18(int) ShiftRightArithmetic 20 21
               65:     23(ptr) AccessChain 17(sbuf) 19 64
-              66:           2 AtomicXor 65 26 27 25
+              66:      6(int) AtomicXor 65 26 27 25
               67:     18(int) ShiftRightArithmetic 20 21
               68:     23(ptr) AccessChain 17(sbuf) 19 67
               69:      6(int) AtomicXor 68 26 27 25

+ 86 - 85
3rdparty/glslang/Test/baseResults/hlsl.structbuffer.floatidx.comp.out

@@ -16,12 +16,12 @@ local_size = (1, 1, 1)
 0:14                0 (const uint)
 0:14            add ( temp uint)
 0:14              AtomicAdd ( temp uint)
-0:14                @count: direct index for structure ( temp int)
-0:14                  'csb@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer int @count})
+0:14                @count: direct index for structure ( temp uint)
+0:14                  'csb@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer uint @count})
 0:14                  Constant:
 0:14                    0 (const int)
 0:14                Constant:
-0:14                  -1 (const int)
+0:14                  4294967295 (const uint)
 0:14              Constant:
 0:14                -1 (const int)
 0:15      Sequence
@@ -83,7 +83,7 @@ local_size = (1, 1, 1)
 0:?   Linker Objects
 0:?     'outtx' (layout( rgba32f) uniform image2D)
 0:?     'csb' (layout( binding=1 row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of structure{ temp 4-component vector of float color,  temp 2-component vector of uint threadId} @data})
-0:?     'csb@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer int @count})
+0:?     'csb@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer uint @count})
 0:?     'rwsb' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of float @data})
 0:?     'nThreadId' ( in 3-component vector of uint GlobalInvocationID)
 
@@ -108,12 +108,12 @@ local_size = (1, 1, 1)
 0:14                0 (const uint)
 0:14            add ( temp uint)
 0:14              AtomicAdd ( temp uint)
-0:14                @count: direct index for structure ( temp int)
-0:14                  'csb@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer int @count})
+0:14                @count: direct index for structure ( temp uint)
+0:14                  'csb@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer uint @count})
 0:14                  Constant:
 0:14                    0 (const int)
 0:14                Constant:
-0:14                  -1 (const int)
+0:14                  4294967295 (const uint)
 0:14              Constant:
 0:14                -1 (const int)
 0:15      Sequence
@@ -175,18 +175,18 @@ local_size = (1, 1, 1)
 0:?   Linker Objects
 0:?     'outtx' (layout( rgba32f) uniform image2D)
 0:?     'csb' (layout( binding=1 row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of structure{ temp 4-component vector of float color,  temp 2-component vector of uint threadId} @data})
-0:?     'csb@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer int @count})
+0:?     'csb@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer uint @count})
 0:?     'rwsb' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of float @data})
 0:?     'nThreadId' ( in 3-component vector of uint GlobalInvocationID)
 
 // Module Version 10000
 // Generated by (magic number): 80006
-// Id's are bound by 84
+// Id's are bound by 85
 
                               Capability Shader
                1:             ExtInstImport  "GLSL.std.450"
                               MemoryModel Logical GLSL450
-                              EntryPoint GLCompute 4  "main" 79
+                              EntryPoint GLCompute 4  "main" 80
                               ExecutionMode 4 LocalSize 1 1 1
                               Source HLSL 500
                               Name 4  "main"
@@ -205,15 +205,15 @@ local_size = (1, 1, 1)
                               Name 26  "csb@count"
                               MemberName 26(csb@count) 0  "@count"
                               Name 28  "csb@count"
-                              Name 48  "coord"
-                              Name 52  "storeTemp"
-                              Name 57  "outtx"
-                              Name 63  "rwsb"
-                              MemberName 63(rwsb) 0  "@data"
-                              Name 65  "rwsb"
-                              Name 77  "nThreadId"
-                              Name 79  "nThreadId"
-                              Name 81  "param"
+                              Name 49  "coord"
+                              Name 53  "storeTemp"
+                              Name 58  "outtx"
+                              Name 64  "rwsb"
+                              MemberName 64(rwsb) 0  "@data"
+                              Name 66  "rwsb"
+                              Name 78  "nThreadId"
+                              Name 80  "nThreadId"
+                              Name 82  "param"
                               MemberDecorate 19(sb_t) 0 Offset 0
                               MemberDecorate 19(sb_t) 1 Offset 16
                               Decorate 20 ArrayStride 32
@@ -224,12 +224,12 @@ local_size = (1, 1, 1)
                               MemberDecorate 26(csb@count) 0 Offset 0
                               Decorate 26(csb@count) BufferBlock
                               Decorate 28(csb@count) DescriptorSet 0
-                              Decorate 57(outtx) DescriptorSet 0
-                              Decorate 62 ArrayStride 16
-                              MemberDecorate 63(rwsb) 0 Offset 0
-                              Decorate 63(rwsb) BufferBlock
-                              Decorate 65(rwsb) DescriptorSet 0
-                              Decorate 79(nThreadId) BuiltIn GlobalInvocationId
+                              Decorate 58(outtx) DescriptorSet 0
+                              Decorate 63 ArrayStride 16
+                              MemberDecorate 64(rwsb) 0 Offset 0
+                              Decorate 64(rwsb) BufferBlock
+                              Decorate 66(rwsb) DescriptorSet 0
+                              Decorate 80(nThreadId) BuiltIn GlobalInvocationId
                2:             TypeVoid
                3:             TypeFunction 2
                6:             TypeInt 32 0
@@ -248,79 +248,80 @@ local_size = (1, 1, 1)
          23(csb):     22(ptr) Variable Uniform
               24:             TypeInt 32 1
               25:     24(int) Constant 0
-   26(csb@count):             TypeStruct 24(int)
+   26(csb@count):             TypeStruct 6(int)
               27:             TypePointer Uniform 26(csb@count)
    28(csb@count):     27(ptr) Variable Uniform
-              29:             TypePointer Uniform 24(int)
-              31:     24(int) Constant 4294967295
+              29:             TypePointer Uniform 6(int)
+              31:      6(int) Constant 4294967295
               32:      6(int) Constant 1
               33:      6(int) Constant 0
-              36:             TypePointer Uniform 19(sb_t)
-              40:             TypePointer Function 14(fvec4)
-              43:     24(int) Constant 1
-              44:             TypePointer Function 15(ivec2)
-              46:             TypeVector 13(float) 2
-              47:             TypePointer Function 46(fvec2)
-              55:             TypeImage 13(float) 2D nonsampled format:Rgba32f
-              56:             TypePointer UniformConstant 55
-       57(outtx):     56(ptr) Variable UniformConstant
-              62:             TypeRuntimeArray 14(fvec4)
-        63(rwsb):             TypeStruct 62
-              64:             TypePointer Uniform 63(rwsb)
-        65(rwsb):     64(ptr) Variable Uniform
-              66:             TypePointer Function 13(float)
-              73:             TypePointer Uniform 14(fvec4)
-              78:             TypePointer Input 7(ivec3)
-   79(nThreadId):     78(ptr) Variable Input
+              35:     24(int) Constant 4294967295
+              37:             TypePointer Uniform 19(sb_t)
+              41:             TypePointer Function 14(fvec4)
+              44:     24(int) Constant 1
+              45:             TypePointer Function 15(ivec2)
+              47:             TypeVector 13(float) 2
+              48:             TypePointer Function 47(fvec2)
+              56:             TypeImage 13(float) 2D nonsampled format:Rgba32f
+              57:             TypePointer UniformConstant 56
+       58(outtx):     57(ptr) Variable UniformConstant
+              63:             TypeRuntimeArray 14(fvec4)
+        64(rwsb):             TypeStruct 63
+              65:             TypePointer Uniform 64(rwsb)
+        66(rwsb):     65(ptr) Variable Uniform
+              67:             TypePointer Function 13(float)
+              74:             TypePointer Uniform 14(fvec4)
+              79:             TypePointer Input 7(ivec3)
+   80(nThreadId):     79(ptr) Variable Input
          4(main):           2 Function None 3
                5:             Label
-   77(nThreadId):      8(ptr) Variable Function
-       81(param):      8(ptr) Variable Function
-              80:    7(ivec3) Load 79(nThreadId)
-                              Store 77(nThreadId) 80
-              82:    7(ivec3) Load 77(nThreadId)
-                              Store 81(param) 82
-              83:           2 FunctionCall 11(@main(vu3;) 81(param)
+   78(nThreadId):      8(ptr) Variable Function
+       82(param):      8(ptr) Variable Function
+              81:    7(ivec3) Load 80(nThreadId)
+                              Store 78(nThreadId) 81
+              83:    7(ivec3) Load 78(nThreadId)
+                              Store 82(param) 83
+              84:           2 FunctionCall 11(@main(vu3;) 82(param)
                               Return
                               FunctionEnd
   11(@main(vu3;):           2 Function None 9
    10(nThreadId):      8(ptr) FunctionParameter
               12:             Label
         18(data):     17(ptr) Variable Function
-       48(coord):     47(ptr) Variable Function
-   52(storeTemp):     40(ptr) Variable Function
+       49(coord):     48(ptr) Variable Function
+   53(storeTemp):     41(ptr) Variable Function
               30:     29(ptr) AccessChain 28(csb@count) 25
               34:      6(int) AtomicIAdd 30 32 33 31
-              35:      6(int) IAdd 34 31
-              37:     36(ptr) AccessChain 23(csb) 25 35
-              38:    19(sb_t) Load 37
-              39:   14(fvec4) CompositeExtract 38 0
-              41:     40(ptr) AccessChain 18(data) 25
-                              Store 41 39
-              42:   15(ivec2) CompositeExtract 38 1
-              45:     44(ptr) AccessChain 18(data) 43
-                              Store 45 42
-              49:     44(ptr) AccessChain 18(data) 43
-              50:   15(ivec2) Load 49
-              51:   46(fvec2) ConvertUToF 50
-                              Store 48(coord) 51
-              53:     40(ptr) AccessChain 18(data) 25
-              54:   14(fvec4) Load 53
-                              Store 52(storeTemp) 54
-              58:          55 Load 57(outtx)
-              59:   46(fvec2) Load 48(coord)
-              60:   15(ivec2) ConvertFToU 59
-              61:   14(fvec4) Load 52(storeTemp)
-                              ImageWrite 58 60 61
-              67:     66(ptr) AccessChain 48(coord) 33
-              68:   13(float) Load 67
-              69:      6(int) ConvertFToU 68
-              70:     66(ptr) AccessChain 48(coord) 32
-              71:   13(float) Load 70
-              72:      6(int) ConvertFToU 71
-              74:     73(ptr) AccessChain 65(rwsb) 25 72
-              75:   14(fvec4) Load 74
-              76:     73(ptr) AccessChain 65(rwsb) 25 69
-                              Store 76 75
+              36:      6(int) IAdd 34 35
+              38:     37(ptr) AccessChain 23(csb) 25 36
+              39:    19(sb_t) Load 38
+              40:   14(fvec4) CompositeExtract 39 0
+              42:     41(ptr) AccessChain 18(data) 25
+                              Store 42 40
+              43:   15(ivec2) CompositeExtract 39 1
+              46:     45(ptr) AccessChain 18(data) 44
+                              Store 46 43
+              50:     45(ptr) AccessChain 18(data) 44
+              51:   15(ivec2) Load 50
+              52:   47(fvec2) ConvertUToF 51
+                              Store 49(coord) 52
+              54:     41(ptr) AccessChain 18(data) 25
+              55:   14(fvec4) Load 54
+                              Store 53(storeTemp) 55
+              59:          56 Load 58(outtx)
+              60:   47(fvec2) Load 49(coord)
+              61:   15(ivec2) ConvertFToU 60
+              62:   14(fvec4) Load 53(storeTemp)
+                              ImageWrite 59 61 62
+              68:     67(ptr) AccessChain 49(coord) 33
+              69:   13(float) Load 68
+              70:      6(int) ConvertFToU 69
+              71:     67(ptr) AccessChain 49(coord) 32
+              72:   13(float) Load 71
+              73:      6(int) ConvertFToU 72
+              75:     74(ptr) AccessChain 66(rwsb) 25 73
+              76:   14(fvec4) Load 75
+              77:     74(ptr) AccessChain 66(rwsb) 25 70
+                              Store 77 76
                               Return
                               FunctionEnd

+ 45 - 45
3rdparty/glslang/Test/baseResults/hlsl.structbuffer.fn.frag.out

@@ -17,7 +17,7 @@ gl_FragCoord origin is upper left
 0:10  Function Definition: set(block--vu4[0]1;u1;vu4; ( temp void)
 0:10    Function Parameters: 
 0:10      'sb' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of uint @data})
-0:10      'sb@count' ( buffer block{layout( row_major std430) buffer int @count})
+0:10      'sb@count' ( buffer block{layout( row_major std430) buffer uint @count})
 0:10      'bufferOffset' ( in uint)
 0:10      'data' ( in 4-component vector of uint)
 0:?     Sequence
@@ -35,7 +35,7 @@ gl_FragCoord origin is upper left
 0:?     Sequence
 0:21      Function Call: set(block--vu4[0]1;u1;vu4; ( temp void)
 0:21        'sbuf2' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of uint @data})
-0:21        'sbuf2@count' ( buffer block{layout( row_major std430) buffer int @count})
+0:21        'sbuf2@count' ( buffer block{layout( row_major std430) buffer uint @count})
 0:21        Constant:
 0:21          2 (const uint)
 0:21        Function Call: get(block--vu4[0]1;u1; ( temp 4-component vector of uint)
@@ -61,7 +61,7 @@ gl_FragCoord origin is upper left
 0:?   Linker Objects
 0:?     'sbuf' (layout( binding=10 row_major std430) readonly buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of uint @data})
 0:?     'sbuf2' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of uint @data})
-0:?     'sbuf2@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer int @count})
+0:?     'sbuf2@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer uint @count})
 0:?     'sbuf3' (layout( binding=12 row_major std430) readonly buffer block{layout( row_major std430) buffer unsized 1-element array of 3-component vector of uint @data})
 0:?     '@entryPointOutput' (layout( location=0) out 4-component vector of float)
 0:?     'pos' (layout( location=0) flat in uint)
@@ -88,7 +88,7 @@ gl_FragCoord origin is upper left
 0:10  Function Definition: set(block--vu4[0]1;u1;vu4; ( temp void)
 0:10    Function Parameters: 
 0:10      'sb' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of uint @data})
-0:10      'sb@count' ( buffer block{layout( row_major std430) buffer int @count})
+0:10      'sb@count' ( buffer block{layout( row_major std430) buffer uint @count})
 0:10      'bufferOffset' ( in uint)
 0:10      'data' ( in 4-component vector of uint)
 0:?     Sequence
@@ -106,7 +106,7 @@ gl_FragCoord origin is upper left
 0:?     Sequence
 0:21      Function Call: set(block--vu4[0]1;u1;vu4; ( temp void)
 0:21        'sbuf2' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of uint @data})
-0:21        'sbuf2@count' ( buffer block{layout( row_major std430) buffer int @count})
+0:21        'sbuf2@count' ( buffer block{layout( row_major std430) buffer uint @count})
 0:21        Constant:
 0:21          2 (const uint)
 0:21        Function Call: get(block--vu4[0]1;u1; ( temp 4-component vector of uint)
@@ -132,7 +132,7 @@ gl_FragCoord origin is upper left
 0:?   Linker Objects
 0:?     'sbuf' (layout( binding=10 row_major std430) readonly buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of uint @data})
 0:?     'sbuf2' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of uint @data})
-0:?     'sbuf2@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer int @count})
+0:?     'sbuf2@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer uint @count})
 0:?     'sbuf3' (layout( binding=12 row_major std430) readonly buffer block{layout( row_major std430) buffer unsized 1-element array of 3-component vector of uint @data})
 0:?     '@entryPointOutput' (layout( location=0) out 4-component vector of float)
 0:?     'pos' (layout( location=0) flat in uint)
@@ -155,15 +155,15 @@ gl_FragCoord origin is upper left
                               Name 14  "bufferOffset"
                               Name 18  ""
                               MemberName 18 0  "@data"
-                              Name 21  ""
-                              MemberName 21 0  "@count"
-                              Name 29  "set(block--vu4[0]1;u1;vu4;"
-                              Name 25  "sb"
-                              Name 26  "sb@count"
-                              Name 27  "bufferOffset"
-                              Name 28  "data"
-                              Name 35  "@main(u1;"
-                              Name 34  "pos"
+                              Name 20  ""
+                              MemberName 20 0  "@count"
+                              Name 28  "set(block--vu4[0]1;u1;vu4;"
+                              Name 24  "sb"
+                              Name 25  "sb@count"
+                              Name 26  "bufferOffset"
+                              Name 27  "data"
+                              Name 34  "@main(u1;"
+                              Name 33  "pos"
                               Name 47  "sbuf2"
                               Name 48  "sbuf2@count"
                               Name 50  "sbuf"
@@ -188,7 +188,7 @@ gl_FragCoord origin is upper left
                               Decorate 17 ArrayStride 16
                               MemberDecorate 18 0 Offset 0
                               Decorate 18 BufferBlock
-                              Decorate 21 BufferBlock
+                              Decorate 20 BufferBlock
                               Decorate 47(sbuf2) DescriptorSet 0
                               Decorate 48(sbuf2@count) DescriptorSet 0
                               Decorate 50(sbuf) DescriptorSet 0
@@ -217,28 +217,28 @@ gl_FragCoord origin is upper left
               17:             TypeRuntimeArray 7(ivec4)
               18:             TypeStruct 17
               19:             TypePointer Uniform 18(struct)
-              20:             TypeInt 32 1
-              21:             TypeStruct 20(int)
-              22:             TypePointer Uniform 21(struct)
-              23:             TypePointer Function 7(ivec4)
-              24:             TypeFunction 2 19(ptr) 22(ptr) 11(ptr) 23(ptr)
-              31:             TypeFloat 32
-              32:             TypeVector 31(float) 4
-              33:             TypeFunction 32(fvec4) 11(ptr)
-              37:     20(int) Constant 0
+              20:             TypeStruct 6(int)
+              21:             TypePointer Uniform 20(struct)
+              22:             TypePointer Function 7(ivec4)
+              23:             TypeFunction 2 19(ptr) 21(ptr) 11(ptr) 22(ptr)
+              30:             TypeFloat 32
+              31:             TypeVector 30(float) 4
+              32:             TypeFunction 31(fvec4) 11(ptr)
+              36:             TypeInt 32 1
+              37:     36(int) Constant 0
               39:             TypePointer Uniform 7(ivec4)
        47(sbuf2):     19(ptr) Variable Uniform
- 48(sbuf2@count):     22(ptr) Variable Uniform
+ 48(sbuf2@count):     21(ptr) Variable Uniform
               49:      6(int) Constant 2
         50(sbuf):     10(ptr) Variable Uniform
               51:      6(int) Constant 3
-              57:   31(float) Constant 0
-              58:   32(fvec4) ConstantComposite 57 57 57 57
+              57:   30(float) Constant 0
+              58:   31(fvec4) ConstantComposite 57 57 57 57
               62:             TypePointer Input 6(int)
          63(pos):     62(ptr) Variable Input
-              65:             TypePointer Output 32(fvec4)
+              65:             TypePointer Output 31(fvec4)
 66(@entryPointOutput):     65(ptr) Variable Output
- 70(sbuf2@count):             TypeStruct 20(int)
+ 70(sbuf2@count):             TypeStruct 6(int)
               71:             TypePointer Uniform 70(sbuf2@count)
  72(sbuf2@count):     71(ptr) Variable Uniform
               73:             TypeVector 6(int) 3
@@ -254,7 +254,7 @@ gl_FragCoord origin is upper left
                               Store 61(pos) 64
               68:      6(int) Load 61(pos)
                               Store 67(param) 68
-              69:   32(fvec4) FunctionCall 35(@main(u1;) 67(param)
+              69:   31(fvec4) FunctionCall 34(@main(u1;) 67(param)
                               Store 66(@entryPointOutput) 69
                               Return
                               FunctionEnd
@@ -267,28 +267,28 @@ gl_FragCoord origin is upper left
               41:    7(ivec4) Load 40
                               ReturnValue 41
                               FunctionEnd
-29(set(block--vu4[0]1;u1;vu4;):           2 Function None 24
-          25(sb):     19(ptr) FunctionParameter
-    26(sb@count):     22(ptr) FunctionParameter
-27(bufferOffset):     11(ptr) FunctionParameter
-        28(data):     23(ptr) FunctionParameter
-              30:             Label
-              44:      6(int) Load 27(bufferOffset)
-              45:    7(ivec4) Load 28(data)
-              46:     39(ptr) AccessChain 25(sb) 37 44
+28(set(block--vu4[0]1;u1;vu4;):           2 Function None 23
+          24(sb):     19(ptr) FunctionParameter
+    25(sb@count):     21(ptr) FunctionParameter
+26(bufferOffset):     11(ptr) FunctionParameter
+        27(data):     22(ptr) FunctionParameter
+              29:             Label
+              44:      6(int) Load 26(bufferOffset)
+              45:    7(ivec4) Load 27(data)
+              46:     39(ptr) AccessChain 24(sb) 37 44
                               Store 46 45
                               Return
                               FunctionEnd
-   35(@main(u1;):   32(fvec4) Function None 33
-         34(pos):     11(ptr) FunctionParameter
-              36:             Label
+   34(@main(u1;):   31(fvec4) Function None 32
+         33(pos):     11(ptr) FunctionParameter
+              35:             Label
        52(param):     11(ptr) Variable Function
        54(param):     11(ptr) Variable Function
-       55(param):     23(ptr) Variable Function
+       55(param):     22(ptr) Variable Function
                               Store 52(param) 51
               53:    7(ivec4) FunctionCall 15(get(block--vu4[0]1;u1;) 50(sbuf) 52(param)
                               Store 54(param) 49
                               Store 55(param) 53
-              56:           2 FunctionCall 29(set(block--vu4[0]1;u1;vu4;) 47(sbuf2) 48(sbuf2@count) 54(param) 55(param)
+              56:           2 FunctionCall 28(set(block--vu4[0]1;u1;vu4;) 47(sbuf2) 48(sbuf2@count) 54(param) 55(param)
                               ReturnValue 58
                               FunctionEnd

+ 19 - 19
3rdparty/glslang/Test/baseResults/hlsl.structbuffer.incdec.frag.hlslfun1.out

@@ -23,8 +23,8 @@ hlsl.structbuffer.incdec.frag
                               Name 34  "sbuf_rw_i@count"
                               MemberName 34(sbuf_rw_i@count) 0  "@count"
                               Name 36  "sbuf_rw_i@count"
-                              Name 42  "c2"
-                              Name 43  "sbuf_rw_d@count"
+                              Name 41  "c2"
+                              Name 42  "sbuf_rw_d@count"
                               Name 61  "pos"
                               Name 63  "pos"
                               Name 66  "@entryPointOutput"
@@ -38,14 +38,14 @@ hlsl.structbuffer.incdec.frag
                               MemberDecorate 34(sbuf_rw_i@count) 0 Offset 0
                               Decorate 34(sbuf_rw_i@count) BufferBlock
                               Decorate 36(sbuf_rw_i@count) DescriptorSet 0
-                              Decorate 43(sbuf_rw_d@count) DescriptorSet 0
+                              Decorate 42(sbuf_rw_d@count) DescriptorSet 0
                               Decorate 63(pos) Flat
                               Decorate 63(pos) Location 0
                               DecorateStringGOOGLE 63(pos) DecorationHlslSemanticGOOGLE  "FOO"
                               Decorate 66(@entryPointOutput) Location 0
                               DecorateStringGOOGLE 66(@entryPointOutput) DecorationHlslSemanticGOOGLE  "SV_TARGET0"
                               DecorateId 22(sbuf_rw_i) DecorationHlslCounterBufferGOOGLE 36(sbuf_rw_i@count)
-                              DecorateId 26(sbuf_rw_d) DecorationHlslCounterBufferGOOGLE 43(sbuf_rw_d@count)
+                              DecorateId 26(sbuf_rw_d) DecorationHlslCounterBufferGOOGLE 42(sbuf_rw_d@count)
                2:             TypeVoid
                3:             TypeFunction 2
                6:             TypeInt 32 0
@@ -70,14 +70,14 @@ hlsl.structbuffer.incdec.frag
               29:      6(int) Constant 2
               30:   14(ivec4) ConstantComposite 29 29 29 29
               31:             TypePointer Uniform 14(ivec4)
-34(sbuf_rw_i@count):             TypeStruct 23(int)
+34(sbuf_rw_i@count):             TypeStruct 6(int)
               35:             TypePointer Uniform 34(sbuf_rw_i@count)
 36(sbuf_rw_i@count):     35(ptr) Variable Uniform
-              37:             TypePointer Uniform 23(int)
-              39:     23(int) Constant 1
-              40:      6(int) Constant 1
-43(sbuf_rw_d@count):     35(ptr) Variable Uniform
-              45:     23(int) Constant 4294967295
+              37:             TypePointer Uniform 6(int)
+              39:      6(int) Constant 1
+42(sbuf_rw_d@count):     35(ptr) Variable Uniform
+              44:      6(int) Constant 4294967295
+              46:     23(int) Constant 4294967295
               62:             TypePointer Input 6(int)
          63(pos):     62(ptr) Variable Input
               65:             TypePointer Output 9(fvec4)
@@ -99,26 +99,26 @@ hlsl.structbuffer.incdec.frag
               13:             Label
       16(result):     15(ptr) Variable Function
           33(c1):      7(ptr) Variable Function
-          42(c2):      7(ptr) Variable Function
+          41(c2):      7(ptr) Variable Function
                               Store 16(result) 18
               32:     31(ptr) AccessChain 27(sbuf_rw_nocounter) 24 28
                               Store 32 30
               38:     37(ptr) AccessChain 36(sbuf_rw_i@count) 24
-              41:      6(int) AtomicIAdd 38 40 17 39
-                              Store 33(c1) 41
-              44:     37(ptr) AccessChain 43(sbuf_rw_d@count) 24
-              46:      6(int) AtomicIAdd 44 40 17 45
-              47:      6(int) IAdd 46 45
-                              Store 42(c2) 47
+              40:      6(int) AtomicIAdd 38 39 17 39
+                              Store 33(c1) 40
+              43:     37(ptr) AccessChain 42(sbuf_rw_d@count) 24
+              45:      6(int) AtomicIAdd 43 39 17 44
+              47:      6(int) IAdd 45 46
+                              Store 41(c2) 47
               48:      7(ptr) AccessChain 16(result) 17
               49:      6(int) Load 48
               50:    8(float) ConvertUToF 49
-              51:      7(ptr) AccessChain 16(result) 40
+              51:      7(ptr) AccessChain 16(result) 39
               52:      6(int) Load 51
               53:    8(float) ConvertUToF 52
               54:      6(int) Load 33(c1)
               55:    8(float) ConvertUToF 54
-              56:      6(int) Load 42(c2)
+              56:      6(int) Load 41(c2)
               57:    8(float) ConvertUToF 56
               58:    9(fvec4) CompositeConstruct 50 53 55 57
                               ReturnValue 58

+ 34 - 34
3rdparty/glslang/Test/baseResults/hlsl.structbuffer.incdec.frag.out

@@ -45,23 +45,23 @@ gl_FragCoord origin is upper left
 0:15        move second child to first child ( temp uint)
 0:15          'c1' ( temp uint)
 0:15          AtomicAdd ( temp uint)
-0:15            @count: direct index for structure ( temp int)
-0:15              'sbuf_rw_i@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer int @count})
+0:15            @count: direct index for structure ( temp uint)
+0:15              'sbuf_rw_i@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer uint @count})
 0:15              Constant:
 0:15                0 (const int)
 0:15            Constant:
-0:15              1 (const int)
+0:15              1 (const uint)
 0:16      Sequence
 0:16        move second child to first child ( temp uint)
 0:16          'c2' ( temp uint)
 0:16          add ( temp uint)
 0:16            AtomicAdd ( temp uint)
-0:16              @count: direct index for structure ( temp int)
-0:16                'sbuf_rw_d@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer int @count})
+0:16              @count: direct index for structure ( temp uint)
+0:16                'sbuf_rw_d@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer uint @count})
 0:16                Constant:
 0:16                  0 (const int)
 0:16              Constant:
-0:16                -1 (const int)
+0:16                4294967295 (const uint)
 0:16            Constant:
 0:16              -1 (const int)
 0:18      Branch: Return with expression
@@ -92,9 +92,9 @@ gl_FragCoord origin is upper left
 0:?           'pos' ( temp uint)
 0:?   Linker Objects
 0:?     'sbuf_rw_i' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of uint @data})
-0:?     'sbuf_rw_i@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer int @count})
+0:?     'sbuf_rw_i@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer uint @count})
 0:?     'sbuf_rw_d' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of uint @data})
-0:?     'sbuf_rw_d@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer int @count})
+0:?     'sbuf_rw_d@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer uint @count})
 0:?     'sbuf_rw_nocounter' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of uint @data})
 0:?     '@entryPointOutput' (layout( location=0) out 4-component vector of float)
 0:?     'pos' (layout( location=0) flat in uint)
@@ -149,23 +149,23 @@ gl_FragCoord origin is upper left
 0:15        move second child to first child ( temp uint)
 0:15          'c1' ( temp uint)
 0:15          AtomicAdd ( temp uint)
-0:15            @count: direct index for structure ( temp int)
-0:15              'sbuf_rw_i@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer int @count})
+0:15            @count: direct index for structure ( temp uint)
+0:15              'sbuf_rw_i@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer uint @count})
 0:15              Constant:
 0:15                0 (const int)
 0:15            Constant:
-0:15              1 (const int)
+0:15              1 (const uint)
 0:16      Sequence
 0:16        move second child to first child ( temp uint)
 0:16          'c2' ( temp uint)
 0:16          add ( temp uint)
 0:16            AtomicAdd ( temp uint)
-0:16              @count: direct index for structure ( temp int)
-0:16                'sbuf_rw_d@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer int @count})
+0:16              @count: direct index for structure ( temp uint)
+0:16                'sbuf_rw_d@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer uint @count})
 0:16                Constant:
 0:16                  0 (const int)
 0:16              Constant:
-0:16                -1 (const int)
+0:16                4294967295 (const uint)
 0:16            Constant:
 0:16              -1 (const int)
 0:18      Branch: Return with expression
@@ -196,9 +196,9 @@ gl_FragCoord origin is upper left
 0:?           'pos' ( temp uint)
 0:?   Linker Objects
 0:?     'sbuf_rw_i' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of uint @data})
-0:?     'sbuf_rw_i@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer int @count})
+0:?     'sbuf_rw_i@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer uint @count})
 0:?     'sbuf_rw_d' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of uint @data})
-0:?     'sbuf_rw_d@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer int @count})
+0:?     'sbuf_rw_d@count' (layout( row_major std430) buffer block{layout( row_major std430) buffer uint @count})
 0:?     'sbuf_rw_nocounter' (layout( row_major std430) buffer block{layout( row_major std430) buffer unsized 1-element array of 4-component vector of uint @data})
 0:?     '@entryPointOutput' (layout( location=0) out 4-component vector of float)
 0:?     'pos' (layout( location=0) flat in uint)
@@ -226,8 +226,8 @@ gl_FragCoord origin is upper left
                               Name 34  "sbuf_rw_i@count"
                               MemberName 34(sbuf_rw_i@count) 0  "@count"
                               Name 36  "sbuf_rw_i@count"
-                              Name 42  "c2"
-                              Name 43  "sbuf_rw_d@count"
+                              Name 41  "c2"
+                              Name 42  "sbuf_rw_d@count"
                               Name 61  "pos"
                               Name 63  "pos"
                               Name 66  "@entryPointOutput"
@@ -241,7 +241,7 @@ gl_FragCoord origin is upper left
                               MemberDecorate 34(sbuf_rw_i@count) 0 Offset 0
                               Decorate 34(sbuf_rw_i@count) BufferBlock
                               Decorate 36(sbuf_rw_i@count) DescriptorSet 0
-                              Decorate 43(sbuf_rw_d@count) DescriptorSet 0
+                              Decorate 42(sbuf_rw_d@count) DescriptorSet 0
                               Decorate 63(pos) Flat
                               Decorate 63(pos) Location 0
                               Decorate 66(@entryPointOutput) Location 0
@@ -269,14 +269,14 @@ gl_FragCoord origin is upper left
               29:      6(int) Constant 2
               30:   14(ivec4) ConstantComposite 29 29 29 29
               31:             TypePointer Uniform 14(ivec4)
-34(sbuf_rw_i@count):             TypeStruct 23(int)
+34(sbuf_rw_i@count):             TypeStruct 6(int)
               35:             TypePointer Uniform 34(sbuf_rw_i@count)
 36(sbuf_rw_i@count):     35(ptr) Variable Uniform
-              37:             TypePointer Uniform 23(int)
-              39:     23(int) Constant 1
-              40:      6(int) Constant 1
-43(sbuf_rw_d@count):     35(ptr) Variable Uniform
-              45:     23(int) Constant 4294967295
+              37:             TypePointer Uniform 6(int)
+              39:      6(int) Constant 1
+42(sbuf_rw_d@count):     35(ptr) Variable Uniform
+              44:      6(int) Constant 4294967295
+              46:     23(int) Constant 4294967295
               62:             TypePointer Input 6(int)
          63(pos):     62(ptr) Variable Input
               65:             TypePointer Output 9(fvec4)
@@ -298,26 +298,26 @@ gl_FragCoord origin is upper left
               13:             Label
       16(result):     15(ptr) Variable Function
           33(c1):      7(ptr) Variable Function
-          42(c2):      7(ptr) Variable Function
+          41(c2):      7(ptr) Variable Function
                               Store 16(result) 18
               32:     31(ptr) AccessChain 27(sbuf_rw_nocounter) 24 28
                               Store 32 30
               38:     37(ptr) AccessChain 36(sbuf_rw_i@count) 24
-              41:      6(int) AtomicIAdd 38 40 17 39
-                              Store 33(c1) 41
-              44:     37(ptr) AccessChain 43(sbuf_rw_d@count) 24
-              46:      6(int) AtomicIAdd 44 40 17 45
-              47:      6(int) IAdd 46 45
-                              Store 42(c2) 47
+              40:      6(int) AtomicIAdd 38 39 17 39
+                              Store 33(c1) 40
+              43:     37(ptr) AccessChain 42(sbuf_rw_d@count) 24
+              45:      6(int) AtomicIAdd 43 39 17 44
+              47:      6(int) IAdd 45 46
+                              Store 41(c2) 47
               48:      7(ptr) AccessChain 16(result) 17
               49:      6(int) Load 48
               50:    8(float) ConvertUToF 49
-              51:      7(ptr) AccessChain 16(result) 40
+              51:      7(ptr) AccessChain 16(result) 39
               52:      6(int) Load 51
               53:    8(float) ConvertUToF 52
               54:      6(int) Load 33(c1)
               55:    8(float) ConvertUToF 54
-              56:      6(int) Load 42(c2)
+              56:      6(int) Load 41(c2)
               57:    8(float) ConvertUToF 56
               58:    9(fvec4) CompositeConstruct 50 53 55 57
                               ReturnValue 58

+ 1 - 0
3rdparty/glslang/Test/baseResults/remap.hlsl.sample.basic.everything.frag.out

@@ -11,6 +11,7 @@ WARNING: 0:4: 'immediate sampler state' : unimplemented
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 5663  "main" 4253 3709
                               ExecutionMode 5663 OriginUpperLeft
+                              ExecutionMode 5663 DepthReplacing
                               Decorate 4727 DescriptorSet 0
                               Decorate 4727 Binding 0
                               Decorate 3305 DescriptorSet 0

+ 1 - 0
3rdparty/glslang/Test/baseResults/remap.hlsl.sample.basic.none.frag.out

@@ -11,6 +11,7 @@ WARNING: 0:4: 'immediate sampler state' : unimplemented
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 188 192
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Source HLSL 500
                               Name 4  "main"
                               Name 8  "PS_OUTPUT"

+ 1 - 0
3rdparty/glslang/Test/baseResults/remap.hlsl.sample.basic.strip.frag.out

@@ -11,6 +11,7 @@ WARNING: 0:4: 'immediate sampler state' : unimplemented
                               MemoryModel Logical GLSL450
                               EntryPoint Fragment 4  "main" 188 192
                               ExecutionMode 4 OriginUpperLeft
+                              ExecutionMode 4 DepthReplacing
                               Decorate 45 DescriptorSet 0
                               Decorate 45 Binding 0
                               Decorate 49 DescriptorSet 0

+ 1 - 1
3rdparty/glslang/Test/baseResults/spv.GeometryShaderPassthrough.geom.out

@@ -11,7 +11,7 @@ spv.GeometryShaderPassthrough.geom
                               EntryPoint Geometry 4  "main" 10 14
                               ExecutionMode 4 Triangles
                               ExecutionMode 4 Invocations 1
-                              ExecutionMode 4 OutputVertices
+                              ExecutionMode 4 OutputVertices 3
                               Source GLSL 450
                               SourceExtension  "GL_NV_geometry_shader_passthrough"
                               Name 4  "main"

+ 16 - 9
3rdparty/glslang/Test/baseResults/spv.noBuiltInLoc.vert.out

@@ -1,12 +1,13 @@
 spv.noBuiltInLoc.vert
 // Module Version 10000
 // Generated by (magic number): 80006
-// Id's are bound by 33
+// Id's are bound by 35
 
                               Capability Shader
+                              Capability AtomicStorage
                1:             ExtInstImport  "GLSL.std.450"
                               MemoryModel Logical GLSL450
-                              EntryPoint Vertex 4  "main" 9 11 18 31 32
+                              EntryPoint Vertex 4  "main" 9 11 18 33 34
                               Source GLSL 450
                               Name 4  "main"
                               Name 9  "bar"
@@ -20,8 +21,9 @@ spv.noBuiltInLoc.vert
                               Name 24  "uv1"
                               Name 26  "uv2"
                               Name 29  "uv3"
-                              Name 31  "gl_VertexID"
-                              Name 32  "gl_InstanceID"
+                              Name 31  "a_uint"
+                              Name 33  "gl_VertexID"
+                              Name 34  "gl_InstanceID"
                               Decorate 9(bar) Location 0
                               Decorate 11(foo) Location 0
                               MemberDecorate 16(gl_PerVertex) 0 BuiltIn Position
@@ -35,8 +37,11 @@ spv.noBuiltInLoc.vert
                               Decorate 26(uv2) DescriptorSet 0
                               Decorate 29(uv3) Location 2
                               Decorate 29(uv3) DescriptorSet 0
-                              Decorate 31(gl_VertexID) BuiltIn VertexId
-                              Decorate 32(gl_InstanceID) BuiltIn InstanceId
+                              Decorate 31(a_uint) Offset 0
+                              Decorate 31(a_uint) DescriptorSet 0
+                              Decorate 31(a_uint) Binding 0
+                              Decorate 33(gl_VertexID) BuiltIn VertexId
+                              Decorate 34(gl_InstanceID) BuiltIn InstanceId
                2:             TypeVoid
                3:             TypeFunction 2
                6:             TypeFloat 32
@@ -60,9 +65,11 @@ spv.noBuiltInLoc.vert
               27:             TypeVector 6(float) 3
               28:             TypePointer UniformConstant 27(fvec3)
          29(uv3):     28(ptr) Variable UniformConstant
-              30:             TypePointer Input 19(int)
- 31(gl_VertexID):     30(ptr) Variable Input
-32(gl_InstanceID):     30(ptr) Variable Input
+              30:             TypePointer AtomicCounter 13(int)
+      31(a_uint):     30(ptr) Variable AtomicCounter
+              32:             TypePointer Input 19(int)
+ 33(gl_VertexID):     32(ptr) Variable Input
+34(gl_InstanceID):     32(ptr) Variable Input
          4(main):           2 Function None 3
                5:             Label
               12:    7(fvec4) Load 11(foo)

+ 38 - 40
3rdparty/glslang/Test/baseResults/spv.ssboAlias.frag.out

@@ -1,12 +1,12 @@
 spv.ssboAlias.frag
 // Module Version 10000
 // Generated by (magic number): 80006
-// Id's are bound by 46
+// Id's are bound by 44
 
                               Capability Shader
                1:             ExtInstImport  "GLSL.std.450"
                               MemoryModel Logical GLSL450
-                              EntryPoint Fragment 4  "main" 43
+                              EntryPoint Fragment 4  "main" 41
                               ExecutionMode 4 OriginUpperLeft
                               Source HLSL 500
                               Name 4  "main"
@@ -17,10 +17,10 @@ spv.ssboAlias.frag
                               Name 18  "Buf1@count"
                               MemberName 18(Buf1@count) 0  "@count"
                               Name 20  "Buf1@count"
-                              Name 30  "Buf2"
-                              Name 31  "Buf2@count"
-                              Name 43  "@entryPointOutput"
-                              Name 45  "Buf3"
+                              Name 28  "Buf2"
+                              Name 29  "Buf2@count"
+                              Name 41  "@entryPointOutput"
+                              Name 43  "Buf3"
                               Decorate 12 ArrayStride 4
                               MemberDecorate 13(Buf1) 0 Offset 0
                               Decorate 13(Buf1) BufferBlock
@@ -30,13 +30,13 @@ spv.ssboAlias.frag
                               Decorate 18(Buf1@count) BufferBlock
                               Decorate 20(Buf1@count) DescriptorSet 0
                               Decorate 20(Buf1@count) Binding 83
-                              Decorate 30(Buf2) DescriptorSet 0
-                              Decorate 30(Buf2) Binding 85
-                              Decorate 31(Buf2@count) DescriptorSet 0
-                              Decorate 31(Buf2@count) Binding 86
-                              Decorate 43(@entryPointOutput) Location 0
-                              Decorate 45(Buf3) DescriptorSet 0
-                              Decorate 45(Buf3) Binding 84
+                              Decorate 28(Buf2) DescriptorSet 0
+                              Decorate 28(Buf2) Binding 85
+                              Decorate 29(Buf2@count) DescriptorSet 0
+                              Decorate 29(Buf2@count) Binding 86
+                              Decorate 41(@entryPointOutput) Location 0
+                              Decorate 43(Buf3) DescriptorSet 0
+                              Decorate 43(Buf3) Binding 84
                2:             TypeVoid
                3:             TypeFunction 2
                6:             TypeFloat 32
@@ -49,40 +49,38 @@ spv.ssboAlias.frag
         15(Buf1):     14(ptr) Variable Uniform
               16:             TypeInt 32 1
               17:     16(int) Constant 0
-  18(Buf1@count):             TypeStruct 16(int)
+  18(Buf1@count):             TypeStruct 11(int)
               19:             TypePointer Uniform 18(Buf1@count)
   20(Buf1@count):     19(ptr) Variable Uniform
-              21:             TypePointer Uniform 16(int)
-              23:     16(int) Constant 1
-              24:     11(int) Constant 1
-              25:     11(int) Constant 0
-              27:     11(int) Constant 10
-              28:             TypePointer Uniform 11(int)
-        30(Buf2):     14(ptr) Variable Uniform
-  31(Buf2@count):     19(ptr) Variable Uniform
-              34:     11(int) Constant 20
-              36:    6(float) Constant 1065353216
-              37:    6(float) Constant 1077936128
-              38:    6(float) Constant 1084227584
-              39:    7(fvec4) ConstantComposite 36 37 38 36
-              42:             TypePointer Output 7(fvec4)
-43(@entryPointOutput):     42(ptr) Variable Output
-        45(Buf3):     14(ptr) Variable Uniform
+              21:             TypePointer Uniform 11(int)
+              23:     11(int) Constant 1
+              24:     11(int) Constant 0
+              26:     11(int) Constant 10
+        28(Buf2):     14(ptr) Variable Uniform
+  29(Buf2@count):     19(ptr) Variable Uniform
+              32:     11(int) Constant 20
+              34:    6(float) Constant 1065353216
+              35:    6(float) Constant 1077936128
+              36:    6(float) Constant 1084227584
+              37:    7(fvec4) ConstantComposite 34 35 36 34
+              40:             TypePointer Output 7(fvec4)
+41(@entryPointOutput):     40(ptr) Variable Output
+        43(Buf3):     14(ptr) Variable Uniform
          4(main):           2 Function None 3
                5:             Label
-              44:    7(fvec4) FunctionCall 9(@main()
-                              Store 43(@entryPointOutput) 44
+              42:    7(fvec4) FunctionCall 9(@main()
+                              Store 41(@entryPointOutput) 42
                               Return
                               FunctionEnd
        9(@main():    7(fvec4) Function None 8
               10:             Label
               22:     21(ptr) AccessChain 20(Buf1@count) 17
-              26:     11(int) AtomicIAdd 22 24 25 23
-              29:     28(ptr) AccessChain 15(Buf1) 17 26
-                              Store 29 27
-              32:     21(ptr) AccessChain 31(Buf2@count) 17
-              33:     11(int) AtomicIAdd 32 24 25 23
-              35:     28(ptr) AccessChain 30(Buf2) 17 33
-                              Store 35 34
-                              ReturnValue 39
+              25:     11(int) AtomicIAdd 22 23 24 23
+              27:     21(ptr) AccessChain 15(Buf1) 17 25
+                              Store 27 26
+              30:     21(ptr) AccessChain 29(Buf2@count) 17
+              31:     11(int) AtomicIAdd 30 23 24 23
+              33:     21(ptr) AccessChain 28(Buf2) 17 31
+                              Store 33 32
+                              ReturnValue 37
                               FunctionEnd

+ 87 - 0
3rdparty/glslang/Test/baseResults/spv.vecMatConstruct.frag.out

@@ -0,0 +1,87 @@
+spv.vecMatConstruct.frag
+// Module Version 10000
+// Generated by (magic number): 80006
+// Id's are bound by 62
+
+                              Capability Shader
+               1:             ExtInstImport  "GLSL.std.450"
+                              MemoryModel Logical GLSL450
+                              EntryPoint Fragment 4  "main"
+                              ExecutionMode 4 OriginUpperLeft
+                              Source GLSL 450
+                              Name 4  "main"
+                              Name 9  "v2"
+                              Name 13  "m"
+                              Name 19  "v3"
+                              Name 27  "v4"
+                              Name 37  "iv2"
+                              Name 45  "iv3"
+                              Name 54  "iv4"
+               2:             TypeVoid
+               3:             TypeFunction 2
+               6:             TypeFloat 32
+               7:             TypeVector 6(float) 2
+               8:             TypePointer Function 7(fvec2)
+              10:             TypeVector 6(float) 3
+              11:             TypeMatrix 10(fvec3) 4
+              12:             TypePointer Function 11
+              18:             TypePointer Function 10(fvec3)
+              25:             TypeVector 6(float) 4
+              26:             TypePointer Function 25(fvec4)
+              34:             TypeInt 32 1
+              35:             TypeVector 34(int) 2
+              36:             TypePointer Function 35(ivec2)
+              43:             TypeVector 34(int) 3
+              44:             TypePointer Function 43(ivec3)
+              52:             TypeVector 34(int) 4
+              53:             TypePointer Function 52(ivec4)
+         4(main):           2 Function None 3
+               5:             Label
+           9(v2):      8(ptr) Variable Function
+           13(m):     12(ptr) Variable Function
+          19(v3):     18(ptr) Variable Function
+          27(v4):     26(ptr) Variable Function
+         37(iv2):     36(ptr) Variable Function
+         45(iv3):     44(ptr) Variable Function
+         54(iv4):     53(ptr) Variable Function
+              14:          11 Load 13(m)
+              15:    6(float) CompositeExtract 14 0 0
+              16:    6(float) CompositeExtract 14 0 1
+              17:    7(fvec2) CompositeConstruct 15 16
+                              Store 9(v2) 17
+              20:          11 Load 13(m)
+              21:    6(float) CompositeExtract 20 0 0
+              22:    6(float) CompositeExtract 20 0 1
+              23:    6(float) CompositeExtract 20 0 2
+              24:   10(fvec3) CompositeConstruct 21 22 23
+                              Store 19(v3) 24
+              28:          11 Load 13(m)
+              29:    6(float) CompositeExtract 28 0 0
+              30:    6(float) CompositeExtract 28 0 1
+              31:    6(float) CompositeExtract 28 0 2
+              32:    6(float) CompositeExtract 28 1 0
+              33:   25(fvec4) CompositeConstruct 29 30 31 32
+                              Store 27(v4) 33
+              38:          11 Load 13(m)
+              39:    6(float) CompositeExtract 38 0 0
+              40:    6(float) CompositeExtract 38 0 1
+              41:    7(fvec2) CompositeConstruct 39 40
+              42:   35(ivec2) ConvertFToS 41
+                              Store 37(iv2) 42
+              46:          11 Load 13(m)
+              47:    6(float) CompositeExtract 46 0 0
+              48:    6(float) CompositeExtract 46 0 1
+              49:    6(float) CompositeExtract 46 0 2
+              50:   10(fvec3) CompositeConstruct 47 48 49
+              51:   43(ivec3) ConvertFToS 50
+                              Store 45(iv3) 51
+              55:          11 Load 13(m)
+              56:    6(float) CompositeExtract 55 0 0
+              57:    6(float) CompositeExtract 55 0 1
+              58:    6(float) CompositeExtract 55 0 2
+              59:    6(float) CompositeExtract 55 1 0
+              60:   25(fvec4) CompositeConstruct 56 57 58 59
+              61:   52(ivec4) ConvertFToS 60
+                              Store 54(iv4) 61
+                              Return
+                              FunctionEnd

+ 2 - 1
3rdparty/glslang/Test/baseResults/vulkan.vert.out

@@ -36,7 +36,8 @@ ERROR: 0:51: '[]' : only outermost dimension of an array of arrays can be a spec
 ERROR: 0:54: '[]' : only outermost dimension of an array of arrays can be a specialization constant 
 ERROR: 0:54: 'location' : SPIR-V requires location for user input/output 
 ERROR: 0:58: 'location' : SPIR-V requires location for user input/output 
-ERROR: 37 compilation errors.  No code generated.
+ERROR: 0:65: 'location' : overlapping use of location 10
+ERROR: 38 compilation errors.  No code generated.
 
 
 SPIR-V is not generated for failed compile or link

+ 2 - 0
3rdparty/glslang/Test/spv.noBuiltInLoc.vert

@@ -10,6 +10,8 @@ uniform vec4 uv1;
 uniform float uv2;
 uniform vec3 uv3;
 
+layout(binding = 0) uniform atomic_uint a_uint;
+
 void main()
 {
     bar = foo;

+ 14 - 0
3rdparty/glslang/Test/spv.vecMatConstruct.frag

@@ -0,0 +1,14 @@
+#version 450
+
+void main()
+{
+    mat4x3 m;
+
+    vec2 v2 = vec2(m);
+    vec3 v3 = vec3(m);
+    vec4 v4 = vec4(m);
+
+    ivec2 iv2 = ivec2(m);
+    ivec3 iv3 = ivec3(m);
+    ivec4 iv4 = ivec4(m);
+}

+ 2 - 0
3rdparty/glslang/Test/vulkan.vert

@@ -61,3 +61,5 @@ out ban2 {
 
 layout(binding = 3000) uniform sampler2D s3000;
 layout(binding = 3001) uniform b3001 { int a; };
+layout(location = 10) in vec4 in1;
+layout(location = 10) in vec4 in2;  // ERROR, no location aliasing

+ 6 - 1
3rdparty/glslang/glslang/CMakeLists.txt

@@ -80,10 +80,15 @@ set(HEADERS
 #                    WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR})
 # set(BISON_GLSLParser_OUTPUT_SOURCE ${CMAKE_CURRENT_SOURCE_DIR}/MachineIndependent/glslang_tab.cpp)
 
-add_library(glslang STATIC ${BISON_GLSLParser_OUTPUT_SOURCE} ${SOURCES} ${HEADERS})
+add_library(glslang ${LIB_TYPE} ${BISON_GLSLParser_OUTPUT_SOURCE} ${SOURCES} ${HEADERS})
 set_property(TARGET glslang PROPERTY FOLDER glslang)
 set_property(TARGET glslang PROPERTY POSITION_INDEPENDENT_CODE ON)
 target_link_libraries(glslang OGLCompiler OSDependent)
+
+if(WIN32 AND BUILD_SHARED_LIBS)
+    set_target_properties(glslang PROPERTIES PREFIX "")
+endif()
+
 if(ENABLE_HLSL)
     target_link_libraries(glslang HLSL)
 endif()

+ 13 - 12
3rdparty/glslang/glslang/Include/Common.h

@@ -67,18 +67,19 @@ std::string to_string(const T& val) {
 #endif
 
 #if defined(_MSC_VER) && _MSC_VER < 1800
-inline long long int strtoll (const char* str, char** endptr, int base)
-{
-  return _strtoi64(str, endptr, base);
-}
-inline unsigned long long int strtoull (const char* str, char** endptr, int base)
-{
-  return _strtoui64(str, endptr, base);
-}
-inline long long int atoll (const char* str)
-{
-  return strtoll(str, NULL, 10);
-}
+    #include <stdlib.h>
+    inline long long int strtoll (const char* str, char** endptr, int base)
+    {
+        return _strtoi64(str, endptr, base);
+    }
+    inline unsigned long long int strtoull (const char* str, char** endptr, int base)
+    {
+        return _strtoui64(str, endptr, base);
+    }
+    inline long long int atoll (const char* str)
+    {
+        return strtoll(str, NULL, 10);
+    }
 #endif
 
 #if defined(_MSC_VER)

+ 1 - 1
3rdparty/glslang/glslang/Include/revision.h

@@ -1,3 +1,3 @@
 // This header is generated by the make-revision script.
 
-#define GLSLANG_PATCH_LEVEL 2676
+#define GLSLANG_PATCH_LEVEL 2691

+ 1 - 0
3rdparty/glslang/glslang/MachineIndependent/Intermediate.cpp

@@ -47,6 +47,7 @@
 
 #include <cfloat>
 #include <utility>
+#include <tuple>
 
 namespace glslang {
 

+ 37 - 1
3rdparty/glslang/glslang/MachineIndependent/ParseHelper.cpp

@@ -3977,6 +3977,28 @@ void TParseContext::finish()
     default:
         break;
     }
+
+#ifdef NV_EXTENSIONS
+    // Set default outputs for GL_NV_geometry_shader_passthrough
+    if (language == EShLangGeometry && extensionTurnedOn(E_SPV_NV_geometry_shader_passthrough)) {
+        if (intermediate.getOutputPrimitive() == ElgNone) {
+            switch (intermediate.getInputPrimitive()) {
+            case ElgPoints:      intermediate.setOutputPrimitive(ElgPoints);    break;
+            case ElgLines:       intermediate.setOutputPrimitive(ElgLineStrip); break;
+            case ElgTriangles:   intermediate.setOutputPrimitive(ElgTriangles); break;
+            default: break;
+            }
+        }
+        if (intermediate.getVertices() == TQualifier::layoutNotSet) {
+            switch (intermediate.getInputPrimitive()) {
+            case ElgPoints:      intermediate.setVertices(1); break;
+            case ElgLines:       intermediate.setVertices(2); break;
+            case ElgTriangles:   intermediate.setVertices(3); break;
+            default: break;
+            }
+        }
+    }
+#endif
 }
 
 //
@@ -5771,8 +5793,22 @@ TIntermTyped* TParseContext::addConstructor(const TSourceLoc& loc, TIntermNode*
 //
 // Returns nullptr for an error or the constructed node.
 //
-TIntermTyped* TParseContext::constructBuiltIn(const TType& type, TOperator op, TIntermTyped* node, const TSourceLoc& loc, bool subset)
+TIntermTyped* TParseContext::constructBuiltIn(const TType& type, TOperator op, TIntermTyped* node, const TSourceLoc& loc,
+    bool subset)
 {
+    // If we are changing a matrix in both domain of basic type and to a non matrix,
+    // do the shape change first (by default, below, basic type is changed before shape).
+    // This avoids requesting a matrix of a new type that is going to be discarded anyway.
+    // TODO: This could be generalized to more type combinations, but that would require
+    // more extensive testing and full algorithm rework. For now, the need to do two changes makes
+    // the recursive call work, and avoids the most aggregious case of creating integer matrices.
+    if (node->getType().isMatrix() && (type.isScalar() || type.isVector()) &&
+            type.isFloatingDomain() != node->getType().isFloatingDomain()) {
+        TType transitionType(node->getBasicType(), glslang::EvqTemporary, type.getVectorSize(), 0, 0, node->isVector());
+        TOperator transitionOp = intermediate.mapTypeToConstructorOp(transitionType);
+        node = constructBuiltIn(transitionType, transitionOp, node, loc, false);
+    }
+
     TIntermTyped* newNode;
     TOperator basicOp;
 

+ 12 - 27
3rdparty/glslang/glslang/MachineIndependent/ShaderLang.cpp

@@ -744,9 +744,9 @@ bool ProcessDeferred(
     const int numPre = 2;
     const int numPost = requireNonempty? 1 : 0;
     const int numTotal = numPre + numStrings + numPost;
-    size_t* lengths = new size_t[numTotal];
-    const char** strings = new const char*[numTotal];
-    const char** names = new const char*[numTotal];
+    std::unique_ptr<size_t[]> lengths(new size_t[numTotal]);
+    std::unique_ptr<const char*[]> strings(new const char*[numTotal]);
+    std::unique_ptr<const char*[]> names(new const char*[numTotal]);
     for (int s = 0; s < numStrings; ++s) {
         strings[s + numPre] = shaderStrings[s];
         if (inputLengths == nullptr || inputLengths[s] < 0)
@@ -834,19 +834,14 @@ bool ProcessDeferred(
                                                   [stage];
 
     // Dynamically allocate the symbol table so we can control when it is deallocated WRT the pool.
-    TSymbolTable* symbolTableMemory = new TSymbolTable;
-    TSymbolTable& symbolTable = *symbolTableMemory;
+    std::unique_ptr<TSymbolTable> symbolTable(new TSymbolTable);
     if (cachedTable)
-        symbolTable.adoptLevels(*cachedTable);
+        symbolTable->adoptLevels(*cachedTable);
 
     // Add built-in symbols that are potentially context dependent;
     // they get popped again further down.
-    if (! AddContextSpecificSymbols(resources, compiler->infoSink, symbolTable, version, profile, spvVersion,
+    if (! AddContextSpecificSymbols(resources, compiler->infoSink, *symbolTable, version, profile, spvVersion,
                                     stage, source)) {
-        delete symbolTableMemory;
-        delete [] lengths;
-        delete [] strings;
-        delete [] names;
         return false;
     }
 
@@ -854,10 +849,9 @@ bool ProcessDeferred(
     // Now we can process the full shader under proper symbols and rules.
     //
 
-    TParseContextBase* parseContext = CreateParseContext(symbolTable, intermediate, version, profile, source,
-                                                         stage, compiler->infoSink,
-                                                         spvVersion, forwardCompatible, messages, false, sourceEntryPointName);
-
+    std::unique_ptr<TParseContextBase> parseContext(CreateParseContext(*symbolTable, intermediate, version, profile, source,
+                                                    stage, compiler->infoSink,
+                                                    spvVersion, forwardCompatible, messages, false, sourceEntryPointName));
     TPpContext ppContext(*parseContext, names[numPre] ? names[numPre] : "", includer);
 
     // only GLSL (bison triggered, really) needs an externally set scan context
@@ -893,23 +887,14 @@ bool ProcessDeferred(
         lengths[postIndex] = strlen(strings[numStrings + numPre]);
         names[postIndex] = nullptr;
     }
-    TInputScanner fullInput(numStrings + numPre + numPost, strings, lengths, names, numPre, numPost);
+    TInputScanner fullInput(numStrings + numPre + numPost, strings.get(), lengths.get(), names.get(), numPre, numPost);
 
     // Push a new symbol allocation scope that will get used for the shader's globals.
-    symbolTable.push();
+    symbolTable->push();
 
     bool success = processingContext(*parseContext, ppContext, fullInput,
-                                     versionWillBeError, symbolTable,
+                                     versionWillBeError, *symbolTable,
                                      intermediate, optLevel, messages);
-
-    // Clean up the symbol table. The AST is self-sufficient now.
-    delete symbolTableMemory;
-
-    delete parseContext;
-    delete [] lengths;
-    delete [] strings;
-    delete [] names;
-
     return success;
 }
 

+ 4 - 4
3rdparty/glslang/glslang/MachineIndependent/Versions.cpp

@@ -892,12 +892,12 @@ void TParseVersions::explicitInt16Check(const TSourceLoc& loc, const char* op, b
 {
     if (! builtIn) {
 #if AMD_EXTENSIONS
-	const char* const extensions[3] = {E_GL_AMD_gpu_shader_int16,
-                                           E_GL_KHX_shader_explicit_arithmetic_types,
-                                           E_GL_KHX_shader_explicit_arithmetic_types_int16};
+        const char* const extensions[3] = {E_GL_AMD_gpu_shader_int16,
+                                            E_GL_KHX_shader_explicit_arithmetic_types,
+                                            E_GL_KHX_shader_explicit_arithmetic_types_int16};
 #else
         const char* const extensions[2] = {E_GL_KHX_shader_explicit_arithmetic_types,
-                                           E_GL_KHX_shader_explicit_arithmetic_types_int16};
+                                            E_GL_KHX_shader_explicit_arithmetic_types_int16};
 #endif
         requireExtensions(loc, sizeof(extensions)/sizeof(extensions[0]), extensions, "explicit types");
         requireProfile(loc, ECoreProfile | ECompatibilityProfile, op);

+ 144 - 144
3rdparty/glslang/glslang/MachineIndependent/glslang.y

@@ -1538,40 +1538,40 @@ type_specifier_nonarray
         $$.setVector(4);
     }
     | F32VEC2 {
-    	parseContext.explicitFloat32Check($1.loc, "float32_t vector", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtFloat;
-    	$$.setVector(2);
+        parseContext.explicitFloat32Check($1.loc, "float32_t vector", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtFloat;
+        $$.setVector(2);
     }
     | F32VEC3 {
-    	parseContext.explicitFloat32Check($1.loc, "float32_t vector", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtFloat;
-    	$$.setVector(3);
+        parseContext.explicitFloat32Check($1.loc, "float32_t vector", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtFloat;
+        $$.setVector(3);
     }
     | F32VEC4 {
-    	parseContext.explicitFloat32Check($1.loc, "float32_t vector", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtFloat;
-    	$$.setVector(4);
+        parseContext.explicitFloat32Check($1.loc, "float32_t vector", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtFloat;
+        $$.setVector(4);
     }
     | F64VEC2 {
-    	parseContext.explicitFloat64Check($1.loc, "float64_t vector", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtDouble;
-    	$$.setVector(2);
+        parseContext.explicitFloat64Check($1.loc, "float64_t vector", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtDouble;
+        $$.setVector(2);
     }
     | F64VEC3 {
-    	parseContext.explicitFloat64Check($1.loc, "float64_t vector", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtDouble;
-    	$$.setVector(3);
+        parseContext.explicitFloat64Check($1.loc, "float64_t vector", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtDouble;
+        $$.setVector(3);
     }
     | F64VEC4 {
-    	parseContext.explicitFloat64Check($1.loc, "float64_t vector", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtDouble;
-    	$$.setVector(4);
+        parseContext.explicitFloat64Check($1.loc, "float64_t vector", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtDouble;
+        $$.setVector(4);
     }
     | BVEC2 {
         $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
@@ -1604,40 +1604,40 @@ type_specifier_nonarray
         $$.setVector(4);
     }
     | I8VEC2 {
- 	   parseContext.explicitInt8Check($1.loc, "8-bit signed integer vector", parseContext.symbolTable.atBuiltInLevel());
- 	   $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
- 	   $$.basicType = EbtInt8;
- 	   $$.setVector(2);
+       parseContext.explicitInt8Check($1.loc, "8-bit signed integer vector", parseContext.symbolTable.atBuiltInLevel());
+       $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+       $$.basicType = EbtInt8;
+       $$.setVector(2);
     }
     | I8VEC3 {
- 	   parseContext.explicitInt8Check($1.loc, "8-bit signed integer vector", parseContext.symbolTable.atBuiltInLevel());
- 	   $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
- 	   $$.basicType = EbtInt8;
- 	   $$.setVector(3);
+       parseContext.explicitInt8Check($1.loc, "8-bit signed integer vector", parseContext.symbolTable.atBuiltInLevel());
+       $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+       $$.basicType = EbtInt8;
+       $$.setVector(3);
     }
     | I8VEC4 {
- 	   parseContext.explicitInt8Check($1.loc, "8-bit signed integer vector", parseContext.symbolTable.atBuiltInLevel());
- 	   $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
- 	   $$.basicType = EbtInt8;
- 	   $$.setVector(4);
+       parseContext.explicitInt8Check($1.loc, "8-bit signed integer vector", parseContext.symbolTable.atBuiltInLevel());
+       $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+       $$.basicType = EbtInt8;
+       $$.setVector(4);
     }
     | I16VEC2 {
- 	   parseContext.explicitInt16Check($1.loc, "16-bit signed integer vector", parseContext.symbolTable.atBuiltInLevel());
- 	   $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
- 	   $$.basicType = EbtInt16;
- 	   $$.setVector(2);
+       parseContext.explicitInt16Check($1.loc, "16-bit signed integer vector", parseContext.symbolTable.atBuiltInLevel());
+       $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+       $$.basicType = EbtInt16;
+       $$.setVector(2);
     }
     | I16VEC3 {
- 	   parseContext.explicitInt16Check($1.loc, "16-bit signed integer vector", parseContext.symbolTable.atBuiltInLevel());
- 	   $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
- 	   $$.basicType = EbtInt16;
- 	   $$.setVector(3);
+       parseContext.explicitInt16Check($1.loc, "16-bit signed integer vector", parseContext.symbolTable.atBuiltInLevel());
+       $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+       $$.basicType = EbtInt16;
+       $$.setVector(3);
     }
     | I16VEC4 {
- 	   parseContext.explicitInt16Check($1.loc, "16-bit signed integer vector", parseContext.symbolTable.atBuiltInLevel());
- 	   $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
- 	   $$.basicType = EbtInt16;
- 	   $$.setVector(4);
+       parseContext.explicitInt16Check($1.loc, "16-bit signed integer vector", parseContext.symbolTable.atBuiltInLevel());
+       $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+       $$.basicType = EbtInt16;
+       $$.setVector(4);
     }
     | I32VEC2 {
         parseContext.explicitInt32Check($1.loc, "32-bit signed integer vector", parseContext.symbolTable.atBuiltInLevel());
@@ -1970,148 +1970,148 @@ type_specifier_nonarray
         $$.setMatrix(4, 4);
     }
     | F32MAT2 {
-    	parseContext.explicitFloat32Check($1.loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtFloat;
-    	$$.setMatrix(2, 2);
+        parseContext.explicitFloat32Check($1.loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtFloat;
+        $$.setMatrix(2, 2);
     }
     | F32MAT3 {
-    	parseContext.explicitFloat32Check($1.loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtFloat;
-    	$$.setMatrix(3, 3);
+        parseContext.explicitFloat32Check($1.loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtFloat;
+        $$.setMatrix(3, 3);
     }
     | F32MAT4 {
-    	parseContext.explicitFloat32Check($1.loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtFloat;
-    	$$.setMatrix(4, 4);
+        parseContext.explicitFloat32Check($1.loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtFloat;
+        $$.setMatrix(4, 4);
     }
     | F32MAT2X2 {
-    	parseContext.explicitFloat32Check($1.loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtFloat;
-    	$$.setMatrix(2, 2);
+        parseContext.explicitFloat32Check($1.loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtFloat;
+        $$.setMatrix(2, 2);
     }
     | F32MAT2X3 {
-    	parseContext.explicitFloat32Check($1.loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtFloat;
-    	$$.setMatrix(2, 3);
+        parseContext.explicitFloat32Check($1.loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtFloat;
+        $$.setMatrix(2, 3);
     }
     | F32MAT2X4 {
-    	parseContext.explicitFloat32Check($1.loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtFloat;
-    	$$.setMatrix(2, 4);
+        parseContext.explicitFloat32Check($1.loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtFloat;
+        $$.setMatrix(2, 4);
     }
     | F32MAT3X2 {
-    	parseContext.explicitFloat32Check($1.loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtFloat;
-    	$$.setMatrix(3, 2);
+        parseContext.explicitFloat32Check($1.loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtFloat;
+        $$.setMatrix(3, 2);
     }
     | F32MAT3X3 {
-    	parseContext.explicitFloat32Check($1.loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtFloat;
-    	$$.setMatrix(3, 3);
+        parseContext.explicitFloat32Check($1.loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtFloat;
+        $$.setMatrix(3, 3);
     }
     | F32MAT3X4 {
-    	parseContext.explicitFloat32Check($1.loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtFloat;
-    	$$.setMatrix(3, 4);
+        parseContext.explicitFloat32Check($1.loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtFloat;
+        $$.setMatrix(3, 4);
     }
     | F32MAT4X2 {
-    	parseContext.explicitFloat32Check($1.loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtFloat;
-    	$$.setMatrix(4, 2);
+        parseContext.explicitFloat32Check($1.loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtFloat;
+        $$.setMatrix(4, 2);
     }
     | F32MAT4X3 {
-    	parseContext.explicitFloat32Check($1.loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtFloat;
-    	$$.setMatrix(4, 3);
+        parseContext.explicitFloat32Check($1.loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtFloat;
+        $$.setMatrix(4, 3);
     }
     | F32MAT4X4 {
-    	parseContext.explicitFloat32Check($1.loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtFloat;
-    	$$.setMatrix(4, 4);
+        parseContext.explicitFloat32Check($1.loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtFloat;
+        $$.setMatrix(4, 4);
     }
     | F64MAT2 {
-    	parseContext.explicitFloat64Check($1.loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtDouble;
-    	$$.setMatrix(2, 2);
+        parseContext.explicitFloat64Check($1.loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtDouble;
+        $$.setMatrix(2, 2);
     }
     | F64MAT3 {
-    	parseContext.explicitFloat64Check($1.loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtDouble;
-    	$$.setMatrix(3, 3);
+        parseContext.explicitFloat64Check($1.loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtDouble;
+        $$.setMatrix(3, 3);
     }
     | F64MAT4 {
-    	parseContext.explicitFloat64Check($1.loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtDouble;
-    	$$.setMatrix(4, 4);
+        parseContext.explicitFloat64Check($1.loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtDouble;
+        $$.setMatrix(4, 4);
     }
     | F64MAT2X2 {
-    	parseContext.explicitFloat64Check($1.loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtDouble;
-    	$$.setMatrix(2, 2);
+        parseContext.explicitFloat64Check($1.loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtDouble;
+        $$.setMatrix(2, 2);
     }
     | F64MAT2X3 {
-    	parseContext.explicitFloat64Check($1.loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtDouble;
-    	$$.setMatrix(2, 3);
+        parseContext.explicitFloat64Check($1.loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtDouble;
+        $$.setMatrix(2, 3);
     }
     | F64MAT2X4 {
-    	parseContext.explicitFloat64Check($1.loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtDouble;
-    	$$.setMatrix(2, 4);
+        parseContext.explicitFloat64Check($1.loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtDouble;
+        $$.setMatrix(2, 4);
     }
     | F64MAT3X2 {
-    	parseContext.explicitFloat64Check($1.loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtDouble;
-    	$$.setMatrix(3, 2);
+        parseContext.explicitFloat64Check($1.loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtDouble;
+        $$.setMatrix(3, 2);
     }
     | F64MAT3X3 {
-    	parseContext.explicitFloat64Check($1.loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtDouble;
-    	$$.setMatrix(3, 3);
+        parseContext.explicitFloat64Check($1.loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtDouble;
+        $$.setMatrix(3, 3);
     }
     | F64MAT3X4 {
-    	parseContext.explicitFloat64Check($1.loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtDouble;
-    	$$.setMatrix(3, 4);
+        parseContext.explicitFloat64Check($1.loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtDouble;
+        $$.setMatrix(3, 4);
     }
     | F64MAT4X2 {
-    	parseContext.explicitFloat64Check($1.loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtDouble;
-    	$$.setMatrix(4, 2);
+        parseContext.explicitFloat64Check($1.loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtDouble;
+        $$.setMatrix(4, 2);
     }
     | F64MAT4X3 {
-    	parseContext.explicitFloat64Check($1.loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtDouble;
-    	$$.setMatrix(4, 3);
+        parseContext.explicitFloat64Check($1.loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtDouble;
+        $$.setMatrix(4, 3);
     }
     | F64MAT4X4 {
-    	parseContext.explicitFloat64Check($1.loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	$$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
-    	$$.basicType = EbtDouble;
-    	$$.setMatrix(4, 4);
+        parseContext.explicitFloat64Check($1.loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        $$.init($1.loc, parseContext.symbolTable.atGlobalLevel());
+        $$.basicType = EbtDouble;
+        $$.setMatrix(4, 4);
     }
     | ATOMIC_UINT {
         parseContext.vulkanRemoved($1.loc, "atomic counter types");

+ 144 - 144
3rdparty/glslang/glslang/MachineIndependent/glslang_tab.cpp

@@ -6102,10 +6102,10 @@ yyreduce:
   case 206:
 #line 1540 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t vector", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtFloat;
-    	(yyval.interm.type).setVector(2);
+        parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t vector", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtFloat;
+        (yyval.interm.type).setVector(2);
     }
 #line 6111 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -6113,10 +6113,10 @@ yyreduce:
   case 207:
 #line 1546 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t vector", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtFloat;
-    	(yyval.interm.type).setVector(3);
+        parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t vector", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtFloat;
+        (yyval.interm.type).setVector(3);
     }
 #line 6122 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -6124,10 +6124,10 @@ yyreduce:
   case 208:
 #line 1552 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t vector", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtFloat;
-    	(yyval.interm.type).setVector(4);
+        parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t vector", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtFloat;
+        (yyval.interm.type).setVector(4);
     }
 #line 6133 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -6135,10 +6135,10 @@ yyreduce:
   case 209:
 #line 1558 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t vector", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtDouble;
-    	(yyval.interm.type).setVector(2);
+        parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t vector", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtDouble;
+        (yyval.interm.type).setVector(2);
     }
 #line 6144 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -6146,10 +6146,10 @@ yyreduce:
   case 210:
 #line 1564 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t vector", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtDouble;
-    	(yyval.interm.type).setVector(3);
+        parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t vector", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtDouble;
+        (yyval.interm.type).setVector(3);
     }
 #line 6155 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -6157,10 +6157,10 @@ yyreduce:
   case 211:
 #line 1570 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t vector", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtDouble;
-    	(yyval.interm.type).setVector(4);
+        parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t vector", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtDouble;
+        (yyval.interm.type).setVector(4);
     }
 #line 6166 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -6228,10 +6228,10 @@ yyreduce:
   case 218:
 #line 1606 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
- 	   parseContext.explicitInt8Check((yyvsp[0].lex).loc, "8-bit signed integer vector", parseContext.symbolTable.atBuiltInLevel());
- 	   (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
- 	   (yyval.interm.type).basicType = EbtInt8;
- 	   (yyval.interm.type).setVector(2);
+       parseContext.explicitInt8Check((yyvsp[0].lex).loc, "8-bit signed integer vector", parseContext.symbolTable.atBuiltInLevel());
+       (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+       (yyval.interm.type).basicType = EbtInt8;
+       (yyval.interm.type).setVector(2);
     }
 #line 6237 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -6239,10 +6239,10 @@ yyreduce:
   case 219:
 #line 1612 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
- 	   parseContext.explicitInt8Check((yyvsp[0].lex).loc, "8-bit signed integer vector", parseContext.symbolTable.atBuiltInLevel());
- 	   (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
- 	   (yyval.interm.type).basicType = EbtInt8;
- 	   (yyval.interm.type).setVector(3);
+       parseContext.explicitInt8Check((yyvsp[0].lex).loc, "8-bit signed integer vector", parseContext.symbolTable.atBuiltInLevel());
+       (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+       (yyval.interm.type).basicType = EbtInt8;
+       (yyval.interm.type).setVector(3);
     }
 #line 6248 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -6250,10 +6250,10 @@ yyreduce:
   case 220:
 #line 1618 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
- 	   parseContext.explicitInt8Check((yyvsp[0].lex).loc, "8-bit signed integer vector", parseContext.symbolTable.atBuiltInLevel());
- 	   (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
- 	   (yyval.interm.type).basicType = EbtInt8;
- 	   (yyval.interm.type).setVector(4);
+       parseContext.explicitInt8Check((yyvsp[0].lex).loc, "8-bit signed integer vector", parseContext.symbolTable.atBuiltInLevel());
+       (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+       (yyval.interm.type).basicType = EbtInt8;
+       (yyval.interm.type).setVector(4);
     }
 #line 6259 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -6261,10 +6261,10 @@ yyreduce:
   case 221:
 #line 1624 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
- 	   parseContext.explicitInt16Check((yyvsp[0].lex).loc, "16-bit signed integer vector", parseContext.symbolTable.atBuiltInLevel());
- 	   (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
- 	   (yyval.interm.type).basicType = EbtInt16;
- 	   (yyval.interm.type).setVector(2);
+       parseContext.explicitInt16Check((yyvsp[0].lex).loc, "16-bit signed integer vector", parseContext.symbolTable.atBuiltInLevel());
+       (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+       (yyval.interm.type).basicType = EbtInt16;
+       (yyval.interm.type).setVector(2);
     }
 #line 6270 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -6272,10 +6272,10 @@ yyreduce:
   case 222:
 #line 1630 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
- 	   parseContext.explicitInt16Check((yyvsp[0].lex).loc, "16-bit signed integer vector", parseContext.symbolTable.atBuiltInLevel());
- 	   (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
- 	   (yyval.interm.type).basicType = EbtInt16;
- 	   (yyval.interm.type).setVector(3);
+       parseContext.explicitInt16Check((yyvsp[0].lex).loc, "16-bit signed integer vector", parseContext.symbolTable.atBuiltInLevel());
+       (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+       (yyval.interm.type).basicType = EbtInt16;
+       (yyval.interm.type).setVector(3);
     }
 #line 6281 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -6283,10 +6283,10 @@ yyreduce:
   case 223:
 #line 1636 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
- 	   parseContext.explicitInt16Check((yyvsp[0].lex).loc, "16-bit signed integer vector", parseContext.symbolTable.atBuiltInLevel());
- 	   (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
- 	   (yyval.interm.type).basicType = EbtInt16;
- 	   (yyval.interm.type).setVector(4);
+       parseContext.explicitInt16Check((yyvsp[0].lex).loc, "16-bit signed integer vector", parseContext.symbolTable.atBuiltInLevel());
+       (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+       (yyval.interm.type).basicType = EbtInt16;
+       (yyval.interm.type).setVector(4);
     }
 #line 6292 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -6909,10 +6909,10 @@ yyreduce:
   case 281:
 #line 1972 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtFloat;
-    	(yyval.interm.type).setMatrix(2, 2);
+        parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtFloat;
+        (yyval.interm.type).setMatrix(2, 2);
     }
 #line 6918 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -6920,10 +6920,10 @@ yyreduce:
   case 282:
 #line 1978 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtFloat;
-    	(yyval.interm.type).setMatrix(3, 3);
+        parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtFloat;
+        (yyval.interm.type).setMatrix(3, 3);
     }
 #line 6929 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -6931,10 +6931,10 @@ yyreduce:
   case 283:
 #line 1984 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtFloat;
-    	(yyval.interm.type).setMatrix(4, 4);
+        parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtFloat;
+        (yyval.interm.type).setMatrix(4, 4);
     }
 #line 6940 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -6942,10 +6942,10 @@ yyreduce:
   case 284:
 #line 1990 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtFloat;
-    	(yyval.interm.type).setMatrix(2, 2);
+        parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtFloat;
+        (yyval.interm.type).setMatrix(2, 2);
     }
 #line 6951 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -6953,10 +6953,10 @@ yyreduce:
   case 285:
 #line 1996 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtFloat;
-    	(yyval.interm.type).setMatrix(2, 3);
+        parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtFloat;
+        (yyval.interm.type).setMatrix(2, 3);
     }
 #line 6962 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -6964,10 +6964,10 @@ yyreduce:
   case 286:
 #line 2002 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtFloat;
-    	(yyval.interm.type).setMatrix(2, 4);
+        parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtFloat;
+        (yyval.interm.type).setMatrix(2, 4);
     }
 #line 6973 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -6975,10 +6975,10 @@ yyreduce:
   case 287:
 #line 2008 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtFloat;
-    	(yyval.interm.type).setMatrix(3, 2);
+        parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtFloat;
+        (yyval.interm.type).setMatrix(3, 2);
     }
 #line 6984 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -6986,10 +6986,10 @@ yyreduce:
   case 288:
 #line 2014 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtFloat;
-    	(yyval.interm.type).setMatrix(3, 3);
+        parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtFloat;
+        (yyval.interm.type).setMatrix(3, 3);
     }
 #line 6995 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -6997,10 +6997,10 @@ yyreduce:
   case 289:
 #line 2020 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtFloat;
-    	(yyval.interm.type).setMatrix(3, 4);
+        parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtFloat;
+        (yyval.interm.type).setMatrix(3, 4);
     }
 #line 7006 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -7008,10 +7008,10 @@ yyreduce:
   case 290:
 #line 2026 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtFloat;
-    	(yyval.interm.type).setMatrix(4, 2);
+        parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtFloat;
+        (yyval.interm.type).setMatrix(4, 2);
     }
 #line 7017 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -7019,10 +7019,10 @@ yyreduce:
   case 291:
 #line 2032 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtFloat;
-    	(yyval.interm.type).setMatrix(4, 3);
+        parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtFloat;
+        (yyval.interm.type).setMatrix(4, 3);
     }
 #line 7028 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -7030,10 +7030,10 @@ yyreduce:
   case 292:
 #line 2038 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtFloat;
-    	(yyval.interm.type).setMatrix(4, 4);
+        parseContext.explicitFloat32Check((yyvsp[0].lex).loc, "float32_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtFloat;
+        (yyval.interm.type).setMatrix(4, 4);
     }
 #line 7039 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -7041,10 +7041,10 @@ yyreduce:
   case 293:
 #line 2044 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtDouble;
-    	(yyval.interm.type).setMatrix(2, 2);
+        parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtDouble;
+        (yyval.interm.type).setMatrix(2, 2);
     }
 #line 7050 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -7052,10 +7052,10 @@ yyreduce:
   case 294:
 #line 2050 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtDouble;
-    	(yyval.interm.type).setMatrix(3, 3);
+        parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtDouble;
+        (yyval.interm.type).setMatrix(3, 3);
     }
 #line 7061 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -7063,10 +7063,10 @@ yyreduce:
   case 295:
 #line 2056 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtDouble;
-    	(yyval.interm.type).setMatrix(4, 4);
+        parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtDouble;
+        (yyval.interm.type).setMatrix(4, 4);
     }
 #line 7072 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -7074,10 +7074,10 @@ yyreduce:
   case 296:
 #line 2062 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtDouble;
-    	(yyval.interm.type).setMatrix(2, 2);
+        parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtDouble;
+        (yyval.interm.type).setMatrix(2, 2);
     }
 #line 7083 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -7085,10 +7085,10 @@ yyreduce:
   case 297:
 #line 2068 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtDouble;
-    	(yyval.interm.type).setMatrix(2, 3);
+        parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtDouble;
+        (yyval.interm.type).setMatrix(2, 3);
     }
 #line 7094 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -7096,10 +7096,10 @@ yyreduce:
   case 298:
 #line 2074 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtDouble;
-    	(yyval.interm.type).setMatrix(2, 4);
+        parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtDouble;
+        (yyval.interm.type).setMatrix(2, 4);
     }
 #line 7105 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -7107,10 +7107,10 @@ yyreduce:
   case 299:
 #line 2080 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtDouble;
-    	(yyval.interm.type).setMatrix(3, 2);
+        parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtDouble;
+        (yyval.interm.type).setMatrix(3, 2);
     }
 #line 7116 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -7118,10 +7118,10 @@ yyreduce:
   case 300:
 #line 2086 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtDouble;
-    	(yyval.interm.type).setMatrix(3, 3);
+        parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtDouble;
+        (yyval.interm.type).setMatrix(3, 3);
     }
 #line 7127 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -7129,10 +7129,10 @@ yyreduce:
   case 301:
 #line 2092 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtDouble;
-    	(yyval.interm.type).setMatrix(3, 4);
+        parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtDouble;
+        (yyval.interm.type).setMatrix(3, 4);
     }
 #line 7138 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -7140,10 +7140,10 @@ yyreduce:
   case 302:
 #line 2098 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtDouble;
-    	(yyval.interm.type).setMatrix(4, 2);
+        parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtDouble;
+        (yyval.interm.type).setMatrix(4, 2);
     }
 #line 7149 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -7151,10 +7151,10 @@ yyreduce:
   case 303:
 #line 2104 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtDouble;
-    	(yyval.interm.type).setMatrix(4, 3);
+        parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtDouble;
+        (yyval.interm.type).setMatrix(4, 3);
     }
 #line 7160 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;
@@ -7162,10 +7162,10 @@ yyreduce:
   case 304:
 #line 2110 "MachineIndependent/glslang.y" /* yacc.c:1646  */
     {
-    	parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
-    	(yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
-    	(yyval.interm.type).basicType = EbtDouble;
-    	(yyval.interm.type).setMatrix(4, 4);
+        parseContext.explicitFloat64Check((yyvsp[0].lex).loc, "float64_t matrix", parseContext.symbolTable.atBuiltInLevel());
+        (yyval.interm.type).init((yyvsp[0].lex).loc, parseContext.symbolTable.atGlobalLevel());
+        (yyval.interm.type).basicType = EbtDouble;
+        (yyval.interm.type).setMatrix(4, 4);
     }
 #line 7171 "MachineIndependent/glslang_tab.cpp" /* yacc.c:1646  */
     break;

+ 1 - 0
3rdparty/glslang/glslang/MachineIndependent/iomapper.cpp

@@ -432,6 +432,7 @@ struct TDefaultIoResolverBase : public glslang::TIoMapResolver
         // no locations added if already present, a built-in variable, a block, or an opaque
         if (type.getQualifier().hasLocation() || type.isBuiltIn() ||
             type.getBasicType() == EbtBlock ||
+            type.getBasicType() == EbtAtomicUint ||
             (type.containsOpaque() && intermediate.getSpv().openGl == 0))
             return -1;
 

+ 2 - 2
3rdparty/glslang/glslang/MachineIndependent/linkValidate.cpp

@@ -847,8 +847,8 @@ int TIntermediate::addUsedLocation(const TQualifier& qualifier, const TType& typ
         // combine location and component ranges
         TIoRange range(locationRange, componentRange, type.getBasicType(), qualifier.hasIndex() ? qualifier.layoutIndex : 0);
 
-        // check for collisions, except for vertex inputs on desktop
-        if (! (profile != EEsProfile && language == EShLangVertex && qualifier.isPipeInput()))
+        // check for collisions, except for vertex inputs on desktop targeting OpenGL
+        if (! (profile != EEsProfile && language == EShLangVertex && qualifier.isPipeInput()) || spvVersion.vulkan > 0)
             collision = checkLocationRange(set, range, type, typeCollision);
 
         if (collision < 0)

+ 1 - 1
3rdparty/glslang/glslang/Public/ShaderLang.h

@@ -671,7 +671,7 @@ public:
     int getUniformBlockSize(int blockIndex) const;         // can be used for glGetActiveUniformBlockiv(UNIFORM_BLOCK_DATA_SIZE)
     int getUniformIndex(const char* name) const;           // can be used for glGetUniformIndices()
     int getUniformBinding(int index) const;                // returns the binding number
-	int getUniformBlockBinding(int index) const;           // returns the block binding number
+    int getUniformBlockBinding(int index) const;           // returns the block binding number
     int getUniformBlockIndex(int index) const;             // can be used for glGetActiveUniformsiv(GL_UNIFORM_BLOCK_INDEX)
     int getUniformBlockCounterIndex(int index) const;      // returns block index of associated counter.
     int getUniformType(int index) const;                   // can be used for glGetActiveUniformsiv(GL_UNIFORM_TYPE)

+ 1 - 0
3rdparty/glslang/gtests/Spv.FromFile.cpp

@@ -322,6 +322,7 @@ INSTANTIATE_TEST_CASE_P(
         "spv.variableArrayIndex.frag",
         "spv.varyingArray.frag",
         "spv.varyingArrayIndirect.frag",
+        "spv.vecMatConstruct.frag",
         "spv.voidFunction.frag",
         "spv.whileLoop.frag",
         "spv.AofA.frag",

+ 5 - 1
3rdparty/glslang/hlsl/CMakeLists.txt

@@ -17,10 +17,14 @@ set(HEADERS
     hlslGrammar.h
     hlslParseables.h)
 
-add_library(HLSL STATIC ${SOURCES} ${HEADERS})
+add_library(HLSL ${LIB_TYPE} ${SOURCES} ${HEADERS})
 set_property(TARGET HLSL PROPERTY FOLDER hlsl)
 set_property(TARGET HLSL PROPERTY POSITION_INDEPENDENT_CODE ON)
 
+if(WIN32 AND BUILD_SHARED_LIBS)
+    set_target_properties(HLSL PROPERTIES PREFIX "")
+endif()
+
 if(WIN32)
     source_group("Source" FILES ${SOURCES} ${HEADERS})
 endif(WIN32)

+ 11 - 4
3rdparty/glslang/hlsl/hlslParseHelper.cpp

@@ -3164,7 +3164,7 @@ bool HlslParseContext::hasStructBuffCounter(const TType& type) const
 void HlslParseContext::counterBufferType(const TSourceLoc& loc, TType& type)
 {
     // Counter type
-    TType* counterType = new TType(EbtInt, EvqBuffer);
+    TType* counterType = new TType(EbtUint, EvqBuffer);
     counterType->setFieldName(intermediate.implicitCounterName);
 
     TTypeList* blockStruct = new TTypeList;
@@ -3216,7 +3216,7 @@ TIntermTyped* HlslParseContext::getStructBufferCounter(const TSourceLoc& loc, TI
     TIntermTyped* index = intermediate.addConstantUnion(0, loc); // index to counter inside block struct
 
     TIntermTyped* counterMember = intermediate.addIndex(EOpIndexDirectStruct, counterVar, index, loc);
-    counterMember->setType(TType(EbtInt));
+    counterMember->setType(TType(EbtUint));
     return counterMember;
 }
 
@@ -3249,7 +3249,7 @@ void HlslParseContext::decomposeStructBufferMethods(const TSourceLoc& loc, TInte
     // Some methods require a hidden internal counter, obtained via getStructBufferCounter().
     // This lambda adds something to it and returns the old value.
     const auto incDecCounter = [&](int incval) -> TIntermTyped* {
-        TIntermTyped* incrementValue = intermediate.addConstantUnion(incval, loc, true);
+        TIntermTyped* incrementValue = intermediate.addConstantUnion(static_cast<unsigned int>(incval), loc, true);
         TIntermTyped* counter = getStructBufferCounter(loc, bufferObj); // obtain the counter member
 
         if (counter == nullptr)
@@ -4815,6 +4815,7 @@ void HlslParseContext::decomposeIntrinsic(const TSourceLoc& loc, TIntermTyped*&
                 } else {
                     // Set the matching operator.  Since output is absent, this is all we need to do.
                     node->getAsAggregate()->setOperator(atomicOp);
+                    node->setType(atomic->getType());
                 }
             }
 
@@ -8629,7 +8630,7 @@ void HlslParseContext::declareBlock(const TSourceLoc& loc, TType& type, const TS
         return;
     }
 
-	// Save it in the AST for linker use.
+    // Save it in the AST for linker use.
     if (symbolTable.atGlobalLevel())
         trackLinkage(variable);
 }
@@ -9342,11 +9343,17 @@ void HlslParseContext::correctOutput(TQualifier& qualifier)
         qualifier.patch = false;
 
     switch (qualifier.builtIn) {
+    case EbvFragDepth:
+        intermediate.setDepthReplacing();
+        intermediate.setDepth(EldAny);
+        break;
     case EbvFragDepthGreater:
+        intermediate.setDepthReplacing();
         intermediate.setDepth(EldGreater);
         qualifier.builtIn = EbvFragDepth;
         break;
     case EbvFragDepthLesser:
+        intermediate.setDepthReplacing();
         intermediate.setDepth(EldLess);
         qualifier.builtIn = EbvFragDepth;
         break;

+ 2 - 2
3rdparty/glslang/known_good.json

@@ -5,14 +5,14 @@
       "site" : "github",
       "subrepo" : "KhronosGroup/SPIRV-Tools",
       "subdir" : "External/spirv-tools",
-      "commit" : "2e644e45785bb221294c32bf02a4ac867de49dc4"
+      "commit" : "26a698c34788bb69123a1f3789970a16cf4d9641"
     },
     {
       "name" : "spirv-tools/external/spirv-headers",
       "site" : "github",
       "subrepo" : "KhronosGroup/SPIRV-Headers",
       "subdir" : "External/spirv-tools/external/spirv-headers",
-      "commit" : "02ffc719aa9f9c1dce5ce05743fb1afe6cbf17ea"
+      "commit" : "12f8de9f04327336b699b1b80aa390ae7f9ddbf4"
     }
   ]
 }