ShaderStorageBlocksWriteAccess not set for spir-v shaders?
!15074 (merged) broke a few tests on radeonsi
including the SPIR-V version https://gitlab.freedesktop.org/mesa/piglit/-/blob/main/tests/spec/arb_gl_spirv/execution/ssbo/unsized-array-length.shader_test
The root cause is that the Result
SSBO isn't tagged as writable by gl_nir_link_uniform because shader_storage_blocks_write_access
is only updated if !prog->data->spirv
.
(because of this, prog->sh.ShaderStorageBlocksWriteAccess
is 0 instead of 3, which then causes tc_set_shader_buffers
to not call tc_buffer_disable_cpu_storage
which breaks the test)
Is this expected? or is this a bug/limitation of gl_nir_link_uniforms
?
cc @tarceri since you wrote a large part of this file.
Edited by Pierre-Eric Pelloux-Prayer