Module: vkd3d Branch: master Commit: eabcaf15fbdff9a003d30559907e5a7373a0dac9 URL: https://gitlab.winehq.org/wine/vkd3d/-/commit/eabcaf15fbdff9a003d30559907e5a...
Author: Henri Verbeet hverbeet@codeweavers.com Date: Mon Jan 22 20:35:28 2024 +0100
vkd3d-shader/ir: Use vsir_instruction_is_dcl() in vsir_validate_instruction().
---
libs/vkd3d-shader/ir.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/libs/vkd3d-shader/ir.c b/libs/vkd3d-shader/ir.c index 82d93cc3..45ccea45 100644 --- a/libs/vkd3d-shader/ir.c +++ b/libs/vkd3d-shader/ir.c @@ -2898,8 +2898,7 @@ static void vsir_validate_instruction(struct validation_context *ctx) * purely structured. In principle we could allow structured * constructs in a block, provided they are confined in a single * block, but need for that hasn't arisen yet, so we don't. */ - if (ctx->cf_type == CF_TYPE_UNKNOWN && !(instruction->handler_idx >= VKD3DSIH_DCL - && instruction->handler_idx <= VKD3DSIH_DCL_VERTICES_OUT)) + if (ctx->cf_type == CF_TYPE_UNKNOWN && !vsir_instruction_is_dcl(instruction)) { if (instruction->handler_idx == VKD3DSIH_LABEL) ctx->cf_type = CF_TYPE_BLOCKS;