5 #extension GL_ARB_shader_bit_encoding: enable
6 #extension GL_ARB_gpu_shader5: enable
8 // To reproduce the Mesa bug, S1 must be larger than 16 bytes and not
9 // 16-byte aligned. In addition, the uniform block must have an instance
28 // base base align padded row- array matrix
29 // align off. off. size major stride stride
30 S1[2] s1_1; // 16 0 0 64 - 32 -
32 // bvec2 bv1 8 0 0 8 - - -
33 // float f1 4 8 8 4 - - -
34 // uvec2 uv1 8 12 16 8 - - -
36 // bvec2 bv1 8 32 32 8 - - -
37 // float f1 4 40 40 4 - - -
38 // uvec2 uv1 8 44 48 8 - - -
39 S3[1] s3_1; // 16 64 64 64 - 64 -
41 // S2 s2_1 16 64 64 64 - - -
42 // mat4x2 m42_1 16 64 64 64 no - 16
45 flat out int vertex_pass;
46 in vec4 piglit_vertex;
48 #if defined(GL_ARB_shader_bit_encoding) || defined(GL_ARB_gpu_shader5) || __VERSION__ >= 430
49 bool float_match(float u, float f, uint bits) { return floatBitsToUint(u) == bits; }
51 bool float_match(float u, float f, uint bits) { return u == f; }
58 pass = float_match(ub.s3_1[0].s2_1.m42_1[0].y, 32703.5333028, 0x46ff7f11u);
60 vertex_pass = int(pass);
61 gl_Position = piglit_vertex;
65 out vec4 piglit_fragcolor;
66 flat in int vertex_pass;
70 piglit_fragcolor = bool(vertex_pass) ? vec4(0, 1, 0, 1) : vec4(1, 0, 0, 1);
76 active uniform UB.s3_1[0].s2_1.m42_1 GL_UNIFORM_TYPE GL_FLOAT_MAT4x2
77 active uniform UB.s3_1[0].s2_1.m42_1 GL_UNIFORM_SIZE 1
78 active uniform UB.s3_1[0].s2_1.m42_1 GL_UNIFORM_OFFSET 64
79 active uniform UB.s3_1[0].s2_1.m42_1 GL_UNIFORM_ARRAY_STRIDE 0
80 active uniform UB.s3_1[0].s2_1.m42_1 GL_UNIFORM_MATRIX_STRIDE 16
81 active uniform UB.s3_1[0].s2_1.m42_1 GL_UNIFORM_IS_ROW_MAJOR 0
83 uniform mat4x2 UB.s3_1[0].s2_1.m42_1 0x4680c6b6 0x46ff7f11 0x462085c4 0x46cefb3e 0xc6b24e67 0x469e776a 0xc6e2d23a 0xc64833be
86 probe all rgba 0.0 1.0 0.0 1.0