From: Jesse Natalie Date: Wed, 15 Mar 2023 16:58:10 +0000 (-0700) Subject: microsoft/compiler: Only set typed UAV load feature bit for multi-comp loads X-Git-Tag: upstream/23.3.3~11200 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=a838f095ef1b92889af7e77bc59e7a640128668d;p=platform%2Fupstream%2Fmesa.git microsoft/compiler: Only set typed UAV load feature bit for multi-comp loads Part-of: --- diff --git a/src/microsoft/compiler/nir_to_dxil.c b/src/microsoft/compiler/nir_to_dxil.c index ce2f3fa..4d5a809 100644 --- a/src/microsoft/compiler/nir_to_dxil.c +++ b/src/microsoft/compiler/nir_to_dxil.c @@ -4056,12 +4056,8 @@ emit_image_load(struct ntd_context *ctx, nir_intrinsic_instr *intr) store_dest(ctx, &intr->dest, i, component, out_type); } - /* FIXME: This flag should be set to true when the RWTexture is attached - * a vector, and we always declare a vec4 right now, so it should always be - * true. Might be worth reworking the dxil_module_get_res_type() to use a - * scalar when the image only has one component. - */ - ctx->mod.feats.typed_uav_load_additional_formats = true; + if (num_components > 1) + ctx->mod.feats.typed_uav_load_additional_formats = true; return true; }