diff options
author | Samuel Iglesias Gonsálvez <[email protected]> | 2018-05-31 11:50:54 +0200 |
---|---|---|
committer | Andres Gomez <[email protected]> | 2019-09-17 23:39:18 +0300 |
commit | 420ad0a1a3d90cf158a4b53c244efb7f4d5610de (patch) | |
tree | bc3888c02fb585a9b134af724527ac420a056f54 | |
parent | 320c36ed3a2a67383d9791a71626e5c5f1ccf59b (diff) |
spirv: check support for SPV_KHR_float_controls capabilities
v2:
- Correct extension name (Caio).
- Rename supported capabilities member (Andres).
Signed-off-by: Samuel Iglesias Gonsálvez <[email protected]>
Reviewed-by: Connor Abbott <[email protected]> [v1]
Reviewed-by: Caio Marcelo de Oliveira Filho <[email protected]>
-rw-r--r-- | src/compiler/shader_info.h | 1 | ||||
-rw-r--r-- | src/compiler/spirv/spirv_to_nir.c | 7 |
2 files changed, 8 insertions, 0 deletions
diff --git a/src/compiler/shader_info.h b/src/compiler/shader_info.h index bd5d2fa0b6c..ae894f3082b 100644 --- a/src/compiler/shader_info.h +++ b/src/compiler/shader_info.h @@ -59,6 +59,7 @@ struct spirv_supported_capabilities { bool physical_storage_buffer_address; bool post_depth_coverage; bool runtime_descriptor_array; + bool float_controls; bool shader_viewport_index_layer; bool stencil_export; bool storage_8bit; diff --git a/src/compiler/spirv/spirv_to_nir.c b/src/compiler/spirv/spirv_to_nir.c index f46af1e42db..acf73ee1952 100644 --- a/src/compiler/spirv/spirv_to_nir.c +++ b/src/compiler/spirv/spirv_to_nir.c @@ -3615,6 +3615,13 @@ vtn_handle_preamble_instruction(struct vtn_builder *b, SpvOp opcode, case SpvCapabilitySampleMaskPostDepthCoverage: spv_check_supported(post_depth_coverage, cap); + + case SpvCapabilityDenormFlushToZero: + case SpvCapabilityDenormPreserve: + case SpvCapabilitySignedZeroInfNanPreserve: + case SpvCapabilityRoundingModeRTE: + case SpvCapabilityRoundingModeRTZ: + spv_check_supported(float_controls, cap); break; case SpvCapabilityPhysicalStorageBufferAddressesEXT: |