From: Jason Ekstrand Date: Thu, 2 Jun 2016 21:36:58 +0000 (-0700) Subject: nir/spirv: Make a decoration switch complete X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=526a8de22d85bcdc3a46b2e16e0073527616d95d;p=mesa.git nir/spirv: Make a decoration switch complete Getting rid of the default case makes the compiler warn if we are missing cases. While we're here, we also add the one missing case. Signed-off-by: Jason Ekstrand Cc: "12.0" --- diff --git a/src/compiler/spirv/spirv_to_nir.c b/src/compiler/spirv/spirv_to_nir.c index f1fa6eedfae..f1bbfd511ff 100644 --- a/src/compiler/spirv/spirv_to_nir.c +++ b/src/compiler/spirv/spirv_to_nir.c @@ -533,6 +533,7 @@ struct_member_decoration_cb(struct vtn_builder *b, case SpvDecorationIndex: case SpvDecorationBinding: case SpvDecorationDescriptorSet: + case SpvDecorationLinkageAttributes: case SpvDecorationNoContraction: case SpvDecorationInputAttachmentIndex: vtn_warn("Decoration not allowed on struct members: %s", @@ -553,9 +554,6 @@ struct_member_decoration_cb(struct vtn_builder *b, vtn_warn("Decoraiton only allowed for CL-style kernels: %s", spirv_decoration_to_string(dec->decoration)); break; - - default: - unreachable("Unhandled member decoration"); } }