spirv: Add support for runtime descriptor array cap.
authorBas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Wed, 11 Apr 2018 23:36:22 +0000 (01:36 +0200)
committerBas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Wed, 18 Apr 2018 20:56:54 +0000 (22:56 +0200)
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
src/compiler/shader_info.h
src/compiler/spirv/spirv_to_nir.c

index 6bbe526d2dc1f2acc44afe81517a10c10a5b5c51..53a0ef21f6f6891caad75a624197f22b0ba27ee0 100644 (file)
@@ -54,6 +54,7 @@ struct spirv_supported_capabilities {
    bool gcn_shader;
    bool trinary_minmax;
    bool descriptor_array_dynamic_indexing;
+   bool runtime_descriptor_array;
 };
 
 typedef struct shader_info {
index 884f5b2c69ea2df5641571936eb52948ed6469d6..2a835f047e4ea48f942d06b3787addb9f28eec4d 100644 (file)
@@ -3390,6 +3390,10 @@ vtn_handle_preamble_instruction(struct vtn_builder *b, SpvOp opcode,
          spv_check_supported(descriptor_array_dynamic_indexing, cap);
          break;
 
+      case SpvCapabilityRuntimeDescriptorArrayEXT:
+         spv_check_supported(runtime_descriptor_array, cap);
+         break;
+
       default:
          vtn_fail("Unhandled capability");
       }