From 501a4c0d73b441d40b3a2532b8e8103f268f7996 Mon Sep 17 00:00:00 2001 From: Bas Nieuwenhuizen Date: Wed, 15 Feb 2017 00:58:41 +0100 Subject: [PATCH] spirv: Add support for SpvCapabilityStorageImageReadWithoutFormat. Signed-off-by: Bas Nieuwenhuizen Reviewed-by: Edward O'Callaghan Reviewed-by: Dave Airlie --- src/compiler/spirv/nir_spirv.h | 1 + src/compiler/spirv/spirv_to_nir.c | 5 ++++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/compiler/spirv/nir_spirv.h b/src/compiler/spirv/nir_spirv.h index e43e9b53825..8864a8f73d7 100644 --- a/src/compiler/spirv/nir_spirv.h +++ b/src/compiler/spirv/nir_spirv.h @@ -49,6 +49,7 @@ struct nir_spirv_supported_extensions { bool image_ms_array; bool tessellation; bool draw_parameters; + bool image_read_without_format; bool image_write_without_format; }; diff --git a/src/compiler/spirv/spirv_to_nir.c b/src/compiler/spirv/spirv_to_nir.c index 7e7874a5e49..8108e1030bf 100644 --- a/src/compiler/spirv/spirv_to_nir.c +++ b/src/compiler/spirv/spirv_to_nir.c @@ -2663,7 +2663,6 @@ vtn_handle_preamble_instruction(struct vtn_builder *b, SpvOp opcode, case SpvCapabilitySparseResidency: case SpvCapabilityMinLod: case SpvCapabilityTransformFeedback: - case SpvCapabilityStorageImageReadWithoutFormat: vtn_warn("Unsupported SPIR-V capability: %s", spirv_capability_to_string(cap)); break; @@ -2699,6 +2698,10 @@ vtn_handle_preamble_instruction(struct vtn_builder *b, SpvOp opcode, spv_check_supported(draw_parameters, cap); break; + case SpvCapabilityStorageImageReadWithoutFormat: + spv_check_supported(image_read_without_format, cap); + break; + case SpvCapabilityStorageImageWriteWithoutFormat: spv_check_supported(image_write_without_format, cap); break; -- 2.30.2