[PATCH vkd3d 1/5] vkd3d-shader: Apply 'Patch' decoration to builtin patch constant inputs.
Conor McCarthy
cmccarthy at codeweavers.com
Mon Sep 13 21:00:35 CDT 2021
Prevents a crash in RADV due to an assertion failure when such inputs
are present.
Signed-off-by: Conor McCarthy <cmccarthy at codeweavers.com>
---
libs/vkd3d-shader/spirv.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/libs/vkd3d-shader/spirv.c b/libs/vkd3d-shader/spirv.c
index 6f948c31..d607bc70 100644
--- a/libs/vkd3d-shader/spirv.c
+++ b/libs/vkd3d-shader/spirv.c
@@ -4548,6 +4548,8 @@ static uint32_t vkd3d_dxbc_compiler_emit_input(struct vkd3d_dxbc_compiler *compi
if (builtin)
{
input_id = vkd3d_dxbc_compiler_emit_builtin_variable(compiler, builtin, storage_class, array_size);
+ if (reg->type == VKD3DSPR_PATCHCONST)
+ vkd3d_spirv_build_op_decorate(builder, input_id, SpvDecorationPatch, NULL, 0);
}
else
{
--
2.32.0
More information about the wine-devel
mailing list