spirv: add SpvCapabilityFragmentMaskAMD
authorSamuel Pitoiset <samuel.pitoiset@gmail.com>
Thu, 16 May 2019 10:25:40 +0000 (12:25 +0200)
committerMarge Bot <eric+marge@anholt.net>
Thu, 23 Jan 2020 10:48:02 +0000 (10:48 +0000)
This new capability is for SPV_AMD_shader_fragment_mask.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3304>

src/compiler/shader_info.h
src/compiler/spirv/spirv_to_nir.c

index cbc22d24636efc905a0171f1e712b6a462343822..4aa138943a7e63c897b7a56b78f2e4b1b364fcea 100644 (file)
@@ -79,6 +79,7 @@ struct spirv_supported_capabilities {
    bool vk_memory_model;
    bool vk_memory_model_device_scope;
    bool float16;
+   bool amd_fragment_mask;
    bool amd_gcn_shader;
    bool amd_shader_ballot;
    bool amd_trinary_minmax;
index 6df936b44f973b753f4522f82aaf14cc06f3f1bd..5e2ed6c27eb480e51d489643a11fedbd5ba1e297 100644 (file)
@@ -4123,6 +4123,10 @@ vtn_handle_preamble_instruction(struct vtn_builder *b, SpvOp opcode,
          spv_check_supported(integer_functions2, cap);
          break;
 
+      case SpvCapabilityFragmentMaskAMD:
+         spv_check_supported(amd_fragment_mask, cap);
+         break;
+
       default:
          vtn_fail("Unhandled capability: %s (%u)",
                   spirv_capability_to_string(cap), cap);