From ea93c5c767d5e75e947411aca784f28c2b051b41 Mon Sep 17 00:00:00 2001 From: Zebediah Figura Date: Tue, 22 Mar 2022 16:59:13 -0500 Subject: [PATCH] vkd3d-shader/hlsl: Write SM4 integer addition instructions. Signed-off-by: Zebediah Figura Signed-off-by: Henri Verbeet Signed-off-by: Matteo Bruni Signed-off-by: Giovanni Mascellani Signed-off-by: Francisco Casas Signed-off-by: Alexandre Julliard --- libs/vkd3d-shader/hlsl_sm4.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/libs/vkd3d-shader/hlsl_sm4.c b/libs/vkd3d-shader/hlsl_sm4.c index dadb9783..94765f9e 100644 --- a/libs/vkd3d-shader/hlsl_sm4.c +++ b/libs/vkd3d-shader/hlsl_sm4.c @@ -1634,6 +1634,11 @@ static void write_sm4_expr(struct hlsl_ctx *ctx, write_sm4_binary_op(buffer, VKD3D_SM4_OP_ADD, &expr->node, arg1, arg2); break; + case HLSL_TYPE_INT: + case HLSL_TYPE_UINT: + write_sm4_binary_op(buffer, VKD3D_SM4_OP_IADD, &expr->node, arg1, arg2); + break; + default: hlsl_fixme(ctx, &expr->node.loc, "SM4 %s addition expression.", dst_type_string->buffer); }