From ef1567c17b9521c0b4bd140b49f5b91fa221cf65 Mon Sep 17 00:00:00 2001 From: Francisco Casas Date: Tue, 29 Aug 2023 18:33:50 -0400 Subject: [PATCH] vkd3d-shader/d3d-asm: Use vkd3d_shader_register.dimension to know when to dump writemask. This change ensures that we don't dump the writemask for registers that have a scalar dimension. For instance, for this shader: float r; float4 main(out float d : DEPTH) : sv_target { d = r; return 0; } we now correctly dump dcl_output oDepth instead of dcl_output oDepth.x --- libs/vkd3d-shader/d3d_asm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libs/vkd3d-shader/d3d_asm.c b/libs/vkd3d-shader/d3d_asm.c index 7df2f163..62b50876 100644 --- a/libs/vkd3d-shader/d3d_asm.c +++ b/libs/vkd3d-shader/d3d_asm.c @@ -1264,7 +1264,7 @@ static void shader_dump_dst_param(struct vkd3d_d3d_asm_compiler *compiler, shader_dump_register(compiler, ¶m->reg, is_declaration); - if (write_mask) + if (write_mask && param->reg.dimension == VSIR_DIMENSION_VEC4) { static const char write_mask_chars[] = "xyzw";