From: Daniel Schürmann Date: Tue, 10 Apr 2018 10:02:44 +0000 (+0200) Subject: nir/spirv: Fix warning and add missing breaks. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=fd5b0e0a64a2af29afa3ac1bc5bda23a1422f64a;p=mesa.git nir/spirv: Fix warning and add missing breaks. Reviewed-by: Jason Ekstrand Reviewed-by: Bas Nieuwenhuizen --- diff --git a/src/compiler/spirv/spirv_to_nir.c b/src/compiler/spirv/spirv_to_nir.c index 78c1e9ff597..28274311c2b 100644 --- a/src/compiler/spirv/spirv_to_nir.c +++ b/src/compiler/spirv/spirv_to_nir.c @@ -3361,10 +3361,12 @@ vtn_handle_preamble_instruction(struct vtn_builder *b, SpvOp opcode, case SpvCapabilityGroupNonUniformQuad: spv_check_supported(subgroup_quad, cap); + break; case SpvCapabilityGroupNonUniformArithmetic: case SpvCapabilityGroupNonUniformClustered: spv_check_supported(subgroup_arithmetic, cap); + break; case SpvCapabilityVariablePointersStorageBuffer: case SpvCapabilityVariablePointers: diff --git a/src/compiler/spirv/vtn_subgroup.c b/src/compiler/spirv/vtn_subgroup.c index bd3143962be..ecec3aa62d0 100644 --- a/src/compiler/spirv/vtn_subgroup.c +++ b/src/compiler/spirv/vtn_subgroup.c @@ -277,6 +277,8 @@ vtn_handle_subgroup(struct vtn_builder *b, SpvOp opcode, case 2: op = nir_intrinsic_quad_swap_diagonal; break; + default: + vtn_fail("Invalid constant value in OpGroupNonUniformQuadSwap"); } vtn_build_subgroup_instr(b, op, val->ssa, vtn_ssa_value(b, w[4]), NULL, 0, 0);