Module: Mesa Branch: main Commit: f30768f1d69dc8e346926645ca913bd923e2e492 URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=f30768f1d69dc8e346926645ca913bd923e2e492
Author: Jesse Natalie <[email protected]> Date: Sat Dec 11 10:16:21 2021 -0800 microsoft/compiler: Lower io Reviewed-by: Enrico Galli <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14175> --- src/microsoft/compiler/nir_to_dxil.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/microsoft/compiler/nir_to_dxil.c b/src/microsoft/compiler/nir_to_dxil.c index 38e08d99616..e66bf26f189 100644 --- a/src/microsoft/compiler/nir_to_dxil.c +++ b/src/microsoft/compiler/nir_to_dxil.c @@ -4958,6 +4958,12 @@ allocate_sysvalues(struct ntd_context *ctx) return true; } +static int +type_size_vec4(const struct glsl_type *type, bool bindless) +{ + return glsl_count_attribute_slots(type, false); +} + bool nir_to_dxil(struct nir_shader *s, const struct nir_to_dxil_options *opts, struct blob *blob) @@ -4993,6 +4999,7 @@ nir_to_dxil(struct nir_shader *s, const struct nir_to_dxil_options *opts, NIR_PASS_V(s, nir_lower_pack); NIR_PASS_V(s, nir_lower_frexp); NIR_PASS_V(s, nir_lower_flrp, 16 | 32 | 64, true); + NIR_PASS_V(s, nir_lower_io, nir_var_shader_in | nir_var_shader_out, type_size_vec4, (nir_lower_io_options)0); optimize_nir(s, opts);
