vkd3d-shader/hlsl: Handle objects in copy propagation.

Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Matteo Bruni <mbruni@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Zebediah Figura
2022-01-21 22:22:26 +01:00
committed by Alexandre Julliard
parent 5e14b843ea
commit 62bcdcda76
2 changed files with 42 additions and 10 deletions

View File

@@ -196,6 +196,8 @@ static void hlsl_type_calculate_reg_size(struct hlsl_ctx *ctx, struct hlsl_type
}
case HLSL_CLASS_OBJECT:
/* For convenience when performing copy propagation. */
type->reg_size = 1;
break;
}
}
@@ -273,6 +275,7 @@ struct hlsl_type *hlsl_new_texture_type(struct hlsl_ctx *ctx, enum hlsl_sampler_
type->dimy = 1;
type->sampler_dim = dim;
type->e.resource_format = format;
hlsl_type_calculate_reg_size(ctx, type);
list_add_tail(&ctx->types, &type->entry);
return type;
}