vkd3d-shader/ir: Expect two sources for LOOP in SM1-3.

This commit is contained in:
Giovanni Mascellani 2023-11-16 22:30:12 +01:00 committed by Alexandre Julliard
parent 73c563ffb7
commit 849a8f3add
Notes: Alexandre Julliard 2023-11-20 22:32:45 +01:00
Approved-by: Giovanni Mascellani (@giomasce)
Approved-by: Henri Verbeet (@hverbeet)
Approved-by: Alexandre Julliard (@julliard)
Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/480

View File

@ -1716,7 +1716,7 @@ static void vsir_validate_instruction(struct validation_context *ctx)
case VKD3DSIH_LOOP:
vsir_validate_dst_count(ctx, instruction, 0);
vsir_validate_src_count(ctx, instruction, 0);
vsir_validate_src_count(ctx, instruction, ctx->parser->shader_version.major <= 3 ? 2 : 0);
if (!vkd3d_array_reserve((void **)&ctx->blocks, &ctx->blocks_capacity, ctx->depth + 1, sizeof(*ctx->blocks)))
return;
ctx->blocks[ctx->depth++] = instruction->handler_idx;