arb_texture_buffer_object: Test clamping of texture buffer's size
Tests that texture buffer's size cannot exceed GL_MAX_TEXTURE_BUFFER_SIZE_ARB even if underlying buffer allows it to be bigger. In other words the size of texture buffer must be clamped to the GL_MAX_TEXTURE_BUFFER_SIZE_ARB by the driver.
However there is an issue I don’t know how to resolve, it’s possible for tests to request more memory than it is available for gpu. E.g. on Haswell with 1.5Gb of memory I get:
i965: Failed to submit batchbuffer: No space left on device
Without any GL_OUT_OF_MEMORY. The failing tests are: image-rgba32ui, sampler-rgba32ui, image-rgba32f, sampler-rgba32f.
On AMD RadeonPro WX 4150 gpu all tests fail with similar error.
In the nearby test
max-size there is a hard-coded maximum size of the buffer, however it doesn’t look like a good solution in this case. What could be done?