glslang/Test/baseResults/460.vert.out
Chow 44e842cd9c Add constant expression with mod
Purpose:
glsl spec allows to define array with the length of the result of  constant expression, the arithmetic operation of "mod(float (7.1), float (4.0))" should be generate the array length at the shader compile time,

but glslang didn't support mod operation for the constant expression in previous implementation;

An example is as following:

###########
#version 460
flat out highp int vtx_out_out0;
void main (void)
{
     float array[int(mod(float (7.1), float (4.0)))];
     vtx_out_out0 =  array.length();
}
###########
2019-12-23 11:29:52 +08:00

52 lines
1.6 KiB
Plaintext

460.vert
Shader version: 460
0:? Sequence
0:7 Function Definition: main( ( global void)
0:7 Function Parameters:
0:? Sequence
0:11 move second child to first child ( temp bool)
0:11 'b1' ( temp bool)
0:11 anyInvocation ( global bool)
0:11 'b1' ( temp bool)
0:12 move second child to first child ( temp bool)
0:12 'b1' ( temp bool)
0:12 allInvocations ( global bool)
0:12 'b1' ( temp bool)
0:13 move second child to first child ( temp bool)
0:13 'b1' ( temp bool)
0:13 allInvocationsEqual ( global bool)
0:13 'b1' ( temp bool)
0:? Linker Objects
0:? 'i' ( global int)
0:? 'f' ( global float)
0:? 'gl_VertexID' ( gl_VertexId int VertexId)
0:? 'gl_InstanceID' ( gl_InstanceId int InstanceId)
Linked vertex stage:
Shader version: 460
0:? Sequence
0:7 Function Definition: main( ( global void)
0:7 Function Parameters:
0:? Sequence
0:11 move second child to first child ( temp bool)
0:11 'b1' ( temp bool)
0:11 anyInvocation ( global bool)
0:11 'b1' ( temp bool)
0:12 move second child to first child ( temp bool)
0:12 'b1' ( temp bool)
0:12 allInvocations ( global bool)
0:12 'b1' ( temp bool)
0:13 move second child to first child ( temp bool)
0:13 'b1' ( temp bool)
0:13 allInvocationsEqual ( global bool)
0:13 'b1' ( temp bool)
0:? Linker Objects
0:? 'i' ( global int)
0:? 'f' ( global float)
0:? 'gl_VertexID' ( gl_VertexId int VertexId)
0:? 'gl_InstanceID' ( gl_InstanceId int InstanceId)