Khronos public bugtracker – Bug 745

Compute shader and atomic counters

Last modified: 2013-06-03 09:59:10 PDT

The OpenGL-mandiated minimum value of GL_MAX_COMPUTE_ATOMIC_COUNTER_BUFFERS is 8. This is surprising, since OpenGL allows GL_MAX_FRAGMENT_ATOMIC_COUNTER_BUFFERS to be 1. Was that intentional or just a typo?

Note that this is even more likely a spec bug due to the fact that GL_MAX_ATOMIC_COUNTER_BUFFER_BINDINGS is only required to be 1. So it seems to be saying that compute shaders can use 8 separate buffers, but you're not guaranteed to be able to *bind* them.

I'm going to resolve this as a wontfix. The minimum for compute was intentionally set higher. For the discrepancy between MAX_ATOMIC_COUNTER_BUFFER_BINDINGS and MAX_COMPUTE_ATOMIC_COUNTER_BUFFERS, it's odd, but not a bug. If MAX_ATOMIC_COUNTER_BUFFER_BINDINGS is less than MAX_COMPUTE_ATOMIC_COUNTER_BUFFERS, it just means that all of the atomic counters referenced by a single compute shader must reside in the smaller set of bound buffers. However, I'll bring this up at the ARB and see if we can up the limits to make them more consistent.