Overview

Hardware kbl_iris
Architecture m64
Status fail
Filtered Status fail
Time 0.016254

See also historical results for this test.

stdout

Conditional Dispatching
Verify that DispatchCompute and DispatchComputeIndirect commands work as expected inside conditional blocks.
1. Render two quads. One will pass depth-test and the second one will not.
2. Use GL_ANY_SAMPLES_PASSED query objects to 'remember' these results.
3. Use DispatchCompute and DispatchComputeIndirect commands inside conditional blocks using both query objects.
4. Verify that DispatchCompute and DispatchComputeIndirect commands are only executed in
    the conditional block that uses query object that has passed depth-test.
Everything works as expected.
glCreateProgram();
// 4137 returned
glCreateShader(GL_VERTEX_SHADER);
// 4138 returned
glAttachShader(4137, 4138);
glDeleteShader(4138);
glShaderSource(4138, 2, 0x00007fff054f3440, 0x0000000000000000);
glCompileShader(4138);
glCreateShader(GL_FRAGMENT_SHADER);
// 4139 returned
glAttachShader(4137, 4139);
glDeleteShader(4139);
glShaderSource(4139, 2, 0x00007fff054f3430, 0x0000000000000000);
glCompileShader(4139);
glLinkProgram(4137);
glGetProgramiv(4137, GL_LINK_STATUS, 0x00007fff054f24f4);
// params = { 1 }
glCreateProgram();
// 4140 returned
glCreateShader(GL_COMPUTE_SHADER);
// 4141 returned
glAttachShader(4140, 4141);
glDeleteShader(4141);
glShaderSource(4141, 2, 0x00007fff054f3440, 0x0000000000000000);
glCompileShader(4141);
glLinkProgram(4140);
glGetProgramiv(4140, GL_LINK_STATUS, 0x00007fff054f24f4);
// params = { 1 }
glGenBuffers(1, 0x000055d993c10a6c);
// buffers = { 2165 }
glBindBufferBase(GL_SHADER_STORAGE_BUFFER, 0, 2165);
glBufferData(GL_SHADER_STORAGE_BUFFER, 4, 0x7fff054f349c, GL_DYNAMIC_COPY);
glGenBuffers(1, 0x000055d993c10a70);
// buffers = { 2166 }
glBindBuffer(GL_DISPATCH_INDIRECT_BUFFER, 2166);
glBufferData(GL_DISPATCH_INDIRECT_BUFFER, 12, 0x7fff054f3490, GL_STATIC_DRAW);
glGenVertexArrays(1, 0x000055d993c10a60);
// arrays = { 1054 }
glGenQueries(2, 0x000055d993c10a64);
// ids = { 32, 33 }
glEnable(GL_DEPTH_TEST);
glClear(GL_DEPTH_BUFFER_BIT|GL_COLOR_BUFFER_BIT);
glUseProgram(4137);
glBindVertexArray(1054);
glBeginQuery(GL_ANY_SAMPLES_PASSED, 32);
glGetUniformLocation(4137, g_depth);
// 0 returned
glUniform1f(0, 0);
glDrawArrays(GL_TRIANGLES, 0, 3);
glEndQuery(GL_ANY_SAMPLES_PASSED);
glBeginQuery(GL_ANY_SAMPLES_PASSED, 33);
glGetUniformLocation(4137, g_depth);
// 0 returned
glUniform1f(0, 0.5);
glDrawArrays(GL_TRIANGLES, 0, 3);
glEndQuery(GL_ANY_SAMPLES_PASSED);
glDisable(GL_DEPTH_TEST);
glUseProgram(4140);
glBeginConditionalRender(32, 0x00008e13);
glDispatchCompute(2, 2, 2);
glMemoryBarrier(0x2000);
glDispatchComputeIndirect(0);
glEndConditionalRender();
glMemoryBarrier(0x2000);
glGetBufferSubData(0x000090d2, 0, 4, 0x7fff054f348c);
glBeginConditionalRender(33, 0x00008e13);
glDispatchCompute(2, 2, 2);
glMemoryBarrier(0x2000);
glDispatchComputeIndirect(0);
glEndConditionalRender();
glMemoryBarrier(0x2000);
glGetBufferSubData(0x000090d2, 0, 4, 0x7fff054f3488);
glReadPixels(0, 0, 400, 300, GL_RGBA, GL_FLOAT, 0x55d9954e9970);
Color at (0, 0) is [0, 0, 0, 1] should be [0, 1, 0, 1].
Test Run() failed
glUseProgram(0);
glDeleteProgram(4137);
glDeleteProgram(4140);
glDeleteVertexArrays(1, { 1054 });
glDeleteQueries(2, { 32, 33 });
glDeleteBuffers(1, { 2165 });
glDeleteBuffers(1, { 2166 });

stderr

pid: 17530