mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2024-11-21 16:46:41 -08:00
vkd3d-shader/ir: Do not emit an instruction number before starting validating instructions.
This commit is contained in:
parent
3285d1ad8c
commit
71dccc0132
Notes:
Henri Verbeet
2024-10-10 20:09:41 +02:00
Approved-by: Giovanni Mascellani (@giomasce) Approved-by: Henri Verbeet (@hverbeet) Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/1167
@ -7060,6 +7060,7 @@ enum vkd3d_result vsir_program_validate(struct vsir_program *program, uint64_t c
|
||||
.null_location = {.source_name = source_name},
|
||||
.status = VKD3D_OK,
|
||||
.phase = VKD3DSIH_INVALID,
|
||||
.invalid_instruction_idx = true,
|
||||
};
|
||||
unsigned int i;
|
||||
|
||||
@ -7088,6 +7089,8 @@ enum vkd3d_result vsir_program_validate(struct vsir_program *program, uint64_t c
|
||||
if (!(ctx.ssas = vkd3d_calloc(ctx.program->ssa_count, sizeof(*ctx.ssas))))
|
||||
goto fail;
|
||||
|
||||
ctx.invalid_instruction_idx = false;
|
||||
|
||||
for (ctx.instruction_idx = 0; ctx.instruction_idx < program->instructions.count
|
||||
&& ctx.status != VKD3D_ERROR_OUT_OF_MEMORY; ++ctx.instruction_idx)
|
||||
vsir_validate_instruction(&ctx);
|
||||
|
Loading…
Reference in New Issue
Block a user