vkd3d-shader/ir: Pass a struct vsir_program to shader_normalise_io_registers().

This commit is contained in:
Henri Verbeet 2024-03-12 20:31:56 +01:00 committed by Alexandre Julliard
parent 8a60814476
commit 674bebe9c9
Notes: Alexandre Julliard 2024-03-14 23:25:38 +01:00
Approved-by: Giovanni Mascellani (@giomasce)
Approved-by: Alexandre Julliard (@julliard)
Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/719

View File

@ -1386,10 +1386,9 @@ static void shader_instruction_normalise_io_params(struct vkd3d_shader_instructi
} }
} }
static enum vkd3d_result shader_normalise_io_registers(struct vkd3d_shader_parser *parser) static enum vkd3d_result vsir_program_normalise_io_registers(struct vsir_program *program)
{ {
struct io_normaliser normaliser = {parser->program.instructions}; struct io_normaliser normaliser = {program->instructions};
struct vsir_program *program = &parser->program;
struct vkd3d_shader_instruction *ins; struct vkd3d_shader_instruction *ins;
bool has_control_point_phase; bool has_control_point_phase;
unsigned int i, j; unsigned int i, j;
@ -4365,7 +4364,7 @@ enum vkd3d_result vkd3d_shader_normalise(struct vkd3d_shader_parser *parser,
return result; return result;
} }
if ((result = shader_normalise_io_registers(parser)) < 0) if ((result = vsir_program_normalise_io_registers(program)) < 0)
return result; return result;
if ((result = instruction_array_normalise_flat_constants(program)) < 0) if ((result = instruction_array_normalise_flat_constants(program)) < 0)