vkd3d-shader: Parse shader model 5 resource strides.

Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Henri Verbeet
2021-02-19 15:57:11 +01:00
committed by Alexandre Julliard
parent d40d8c858e
commit 3bacb33556
3 changed files with 18 additions and 7 deletions

View File

@@ -1635,6 +1635,16 @@ static void shader_dump_instruction(struct vkd3d_d3d_asm_compiler *compiler,
default:
shader_dump_instruction_flags(compiler, ins);
if (ins->resource_type != VKD3D_SHADER_RESOURCE_NONE)
{
shader_addline(buffer, "_indexable(");
shader_dump_resource_type(compiler, ins->resource_type);
if (ins->resource_stride)
shader_print_uint_literal(compiler, ", stride=", ins->resource_stride, "");
shader_addline(buffer, ")");
}
if (vkd3d_shader_instruction_has_texel_offset(ins))
{
shader_print_int_literal(compiler, "(", ins->texel_offset.u, "");
@@ -1642,13 +1652,6 @@ static void shader_dump_instruction(struct vkd3d_d3d_asm_compiler *compiler,
shader_print_int_literal(compiler, ",", ins->texel_offset.w, ")");
}
if (ins->resource_type != VKD3D_SHADER_RESOURCE_NONE)
{
shader_addline(buffer, "(");
shader_dump_resource_type(compiler, ins->resource_type);
shader_addline(buffer, ")");
}
if (ins->resource_data_type[0] != VKD3D_DATA_FLOAT
|| ins->resource_data_type[1] != VKD3D_DATA_FLOAT
|| ins->resource_data_type[2] != VKD3D_DATA_FLOAT