diff --git a/libs/vkd3d-shader/spirv.c b/libs/vkd3d-shader/spirv.c index d92b7b13..6eb1537f 100644 --- a/libs/vkd3d-shader/spirv.c +++ b/libs/vkd3d-shader/spirv.c @@ -87,6 +87,10 @@ static void vkd3d_spirv_validate(const struct vkd3d_shader_code *spirv) {} #endif /* HAVE_SPIRV_TOOLS */ +#define VKD3D_SPIRV_GENERATOR_ID 18 +#define VKD3D_SPIRV_GENERATOR_VERSION 0 +#define VKD3D_SPIRV_GENERATOR_MAGIC ((VKD3D_SPIRV_GENERATOR_ID << 16) | VKD3D_SPIRV_GENERATOR_VERSION) + struct vkd3d_spirv_stream { uint32_t *words; @@ -1535,7 +1539,7 @@ static bool vkd3d_spirv_compile_module(struct vkd3d_spirv_builder *builder, vkd3d_spirv_build_word(&stream, SpvMagicNumber); vkd3d_spirv_build_word(&stream, SpvVersion); - vkd3d_spirv_build_word(&stream, 0); /* generator */ + vkd3d_spirv_build_word(&stream, VKD3D_SPIRV_GENERATOR_MAGIC); vkd3d_spirv_build_word(&stream, builder->current_id); /* bound */ vkd3d_spirv_build_word(&stream, 0); /* schema, reserved */