Is there some AMD mailing list for driver bug reports?
anyway, i found the following bug in their GLSL compiler:
this pixel shader
#version 330
out vec4 color0;
void main() {
const float a = 13;
float b = clamp(a, 0, 1);
color0 = vec4(b);
}
outputs vec4(0,0,0,0) instead of vec4(1,1,1,1)
if the “const” qualifier is removed from the variable a, then it works normally. same goes to the “clamp” operation.
apparently the bug is with the const-folding of “clamp” when the first argument is variable with “const” qualifier.