From: Jason Ekstrand Date: Mon, 19 Aug 2019 01:53:24 +0000 (-0500) Subject: nir: Add more source types to nir_tex_instr_src_type X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=5167e94f2343d1dc7db489e7041d89a598eaa68d;p=mesa.git nir: Add more source types to nir_tex_instr_src_type Reviewed-by: Dave Airlie Reviewed-by: Alyssa Rosenzweig --- diff --git a/src/compiler/nir/nir.h b/src/compiler/nir/nir.h index 09a3be5527e..f00cc3fdc50 100644 --- a/src/compiler/nir/nir.h +++ b/src/compiler/nir/nir.h @@ -1827,19 +1827,30 @@ nir_tex_instr_src_type(const nir_tex_instr *instr, unsigned src) case nir_tex_src_projector: case nir_tex_src_comparator: case nir_tex_src_bias: + case nir_tex_src_min_lod: case nir_tex_src_ddx: case nir_tex_src_ddy: return nir_type_float; case nir_tex_src_offset: case nir_tex_src_ms_index: + case nir_tex_src_plane: + return nir_type_int; + + case nir_tex_src_ms_mcs: + case nir_tex_src_texture_deref: + case nir_tex_src_sampler_deref: case nir_tex_src_texture_offset: case nir_tex_src_sampler_offset: - return nir_type_int; + case nir_tex_src_texture_handle: + case nir_tex_src_sampler_handle: + return nir_type_uint; - default: - unreachable("Invalid texture source type"); + case nir_num_tex_src_types: + unreachable("nir_num_tex_src_types is not a valid source type"); } + + unreachable("Invalid texture source type"); } static inline unsigned