diff --git a/reference/shaders-no-opt/asm/comp/block-undef.noeliminate.invalid.asm.comp b/reference/shaders-no-opt/asm/comp/block-undef.noeliminate.invalid.asm.comp index dba99a048..bdab52d9f 100644 --- a/reference/shaders-no-opt/asm/comp/block-undef.noeliminate.invalid.asm.comp +++ b/reference/shaders-no-opt/asm/comp/block-undef.noeliminate.invalid.asm.comp @@ -7,6 +7,11 @@ struct FHitGroupRootConstants uint UserData; }; +layout(binding = 20, std430) readonly buffer type_StructuredBuffer_FHitGroupRootConstants +{ + FHitGroupRootConstants _RESERVED_IDENTIFIER_FIXUP_m0[]; +} HitGroupData; + void main() { } diff --git a/spirv_glsl.cpp b/spirv_glsl.cpp index f5657f2ba..d8d509f47 100644 --- a/spirv_glsl.cpp +++ b/spirv_glsl.cpp @@ -3693,11 +3693,11 @@ void CompilerGLSL::emit_resources() auto &type = this->get(undef.basetype); // OpUndef can be void for some reason ... if (type.basetype == SPIRType::Void) - return; + continue; // This will break. It is bogus and should not be legal. if (type_is_top_level_block(type)) - return; + continue; string initializer; if (options.force_zero_initialized_variables && type_can_zero_initialize(type))