[Mesa-dev] [PATCH] spirv: add missing switch case in vtn_handle_texture()

Jason Ekstrand jason at jlekstrand.net
Wed May 18 02:36:43 UTC 2016


On Tue, May 17, 2016 at 6:30 PM, Brian Paul <brianp at vmware.com> wrote:

> To silence warning:
> spirv/spirv_to_nir.c:1397:4: warning: enumeration value
> 'nir_texop_txf_ms_mcs' not handled in switch [-Wswitch]
>     switch (instr->op) {
>     ^
> ---
>  src/compiler/spirv/spirv_to_nir.c | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/src/compiler/spirv/spirv_to_nir.c
> b/src/compiler/spirv/spirv_to_nir.c
> index c65f971..610044a 100644
> --- a/src/compiler/spirv/spirv_to_nir.c
> +++ b/src/compiler/spirv/spirv_to_nir.c
> @@ -1404,6 +1404,7 @@ vtn_handle_texture(struct vtn_builder *b, SpvOp
> opcode,
>        break;
>     case nir_texop_txf:
>     case nir_texop_txf_ms:
> +   case nir_texop_txf_ms_mcs:
>

Really, that should go in it's own section of the switch with an
unreachable()


>     case nir_texop_txs:
>     case nir_texop_lod:
>     case nir_texop_tg4:
> --
> 1.9.1
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/mesa-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20160517/5350ef07/attachment.html>


More information about the mesa-dev mailing list