KhronosGroup / KhronosGroup/glslang
m4x4._m03_m13_m23 causes crash in glslang (float3 subset of float4x4)
- Dominant language
- C++
- Stars
- 3.6k
- Forks
- 989
- Avg merge
- 1d 2h
- Merged PRs (30d)
- 31
Description
I am having a crash in glslangValidator when compiling
[TerrainVS.hlsl.txt](https://github.com/KhronosGroup/glslang/files/1850314/TerrainVS.hlsl.txt) (Please rename it to TerrainVS.hlsl) and [ZPrePassVS.hlsl.txt](https://github.com/KhronosGroup/glslang/files/1850332/ZPrePassVS.hlsl.txt) (Please rename it to ZPrePassVS.hlsl). The command line I use to compile the shader is as follows:
```
.\glslangValidator.exe -D -fhlsl_functionality1 .\TerrainVS.hlsl -o TerrainVS.spv --target-env vulkan1.0 -S vert -e TerrainVS -V100
.\glslangValidator.exe -D -fhlsl_functionality1 .\ZPrePassVS.hlsl -o ZPrePassVS.spv --target-env vulkan1.0 -S vert -e Common_ZPrepassVS -V100
```
Contributor guide
Research direction
Rename the attached TerrainVS.hlsl.txt and ZPrePassVS.hlsl.txt files, then run the two provided glslangValidator commands to reproduce the crash. Trace handling of m4x4._m03_m13_m23 when a float3 is used as a subset of float4x4. Done means both shaders compile without glslangValidator crashing.
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
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 50/100