When binding a buffer for an array of atomics, the buffer size needs
to be large enough to cover the entire array, or else you will get
undefined behavior. For the atomic buffer case where using
glBindBufferRange to bind only part of the sparse buffer, we were
only providing a size argument large enough for half of the array.
VK-GL-CTS issue 595
Components: OpenGL
Affects:
KHR-GL43.sparse_buffer_tests.BufferStorageTest
KHR-GL44.sparse_buffer_tests.BufferStorageTest
KHR-GL45.sparse_buffer_tests.BufferStorageTest
Change-Id: I8e0a67619801a6071cf53374ae9f06672782dfa0
else
{
m_gl.bindBufferRange(GL_ATOMIC_COUNTER_BUFFER, 0, /* index */
- m_sparse_bo, m_sparse_bo_data_start_offset, m_sparse_bo_data_size);
+ m_sparse_bo, m_sparse_bo_data_start_offset, m_helper_bo_size);
GLU_EXPECT_NO_ERROR(m_gl.getError(), "glBindBufferRange() call failed.");
}