KhronosGroup / KhronosGroup/glslang

Crash when compiling with non-semantic debuginfo

Open
#3,189 5 comments 0 reactions 0 assignees View on GitHub
bug GLSL/ESSL ShaderDebugInfo SPIR-V
Dominant language
C++
Stars
3.6k
Forks
989
Avg merge
1d 2h
Merged PRs (30d)
31

Description

When compiling the shader in the attached file with `glslangValidator -gVS --target-env vulkan1.3 3188.frag -o 3188.dbg.spv`, glslang crashes with the following assert:

glslangValidator: /home/arcady/glslang/SPIRV/SpvBuilder.cpp:967: spv::Id spv::Builder::makeMemberDebugType(const spv::Id, const spv::Builder::DebugTypeLoc &): Assertion `debugId[memberType] != 0' failed.

https://github.com/KhronosGroup/glslang/files/11224475/glslang.3188.zip

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the crash with glslangValidator -gVS --target-env vulkan1.3 3188.frag -o 3188.dbg.spv using the attached glslang.3188.zip. Read SPIRV/SpvBuilder.cpp around line 967 and trace the failing makeMemberDebugType assertion; done means the supplied shader compiles without the assertion and the relevant regression is covered.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
compilers
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.