In mailing thread “[Mesa-dev] Implementation of VK_KHR_draw_indirect_count extension for anv” Jason Ekstrand mentioned that the simultaneous use of these extensions could cause incorrect work on i965. And he is right. Now implementation of ARB_indirect_parameters doesn’t consider situation when predicate is already used by conditional rendering and should be taken into account.
Piglit test can found here: https://patchwork.freedesktop.org/patch/262127/
I’ve fixed this case by using additional registers and mi math. The source of inspiration was Danylo’s implementation of VK_KHR_draw_indirect_count extension. This fix has to work on hsw+, but I exactly know it works correctly on kbl.
(In reply to Illia Iorin from comment #1)
> Piglit test can found here: https://patchwork.freedesktop.org/patch/262127/
I lost most of my mail box, so I don't have this patch to reply to. I have two pieces of feedback.
1. The test requires OpenGL 3.2, so it should use glBeginConditionalRender instead of glBeginConditionalRenderNV. Drop the requirement for the NV extension. Conditional rendering was made part of the GL spec in 3.0. It should also mention "conditional rendering" in the description instead of GL_NV_conditional_render. I think I gave similar feedback earlier today on the Mesa MR.
2. The test uses atomic counters, but it does not check that extension. I doubt any driver will ever support GL_ARB_indirect_parameters and not GL_ARB_shader_atomic_counters, but still. :)
-- GitLab Migration Automatic Message --
This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity.
You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/mesa/mesa/issues/1771.