KhronosGroup / KhronosGroup/glslang

glslang should report a link error if none of the computer shaders contain a fixed work group size

Open
#2,622 0 comments 0 reactions 1 assignee Claimed by @greg-lunarg View on GitHub
bug GLSL/ESSL
Dominant language
C++
Stars
3.6k
Forks
989
Avg merge
1d 2h
Merged PRs (30d)
31

Description

glslang should report a link error if none of the computer shaders contain a fixed work group size.
From GLSLangSpec.4.60, glslang chapter 4.4.1 and page 76.
"Furthermore, if a program object contains any compute shaders, at least one must contain an input
layout qualifier specifying a fixed workgroup size for the program, or a link-time error will occur."

below is the test case which link success, thx~

eg. comp shader 0

#version 430 core
void Run();
void main() {
Run();
}

eg. comp shader 1

#version 430 core
layout(std430) buffer Output {
uint g_output[];
};
void Run() {
g_output[gl_GlobalInvocationID.x] = 0;
}

cmd:
glslangValidator.exe debug0.comp debug1.comp -l -i

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.