[Mesa-dev] [PATCH 0/2] Improve emitted code for copies of large buffer-backed variables
Iago Toral Quiroga
itoral at igalia.com
Mon Nov 23 04:53:07 PST 2015
Fixes linking issues when copying large variables backed by buffers (ubos, ssbos, etc).
In these cases, lower_ubo_reference would split the rhs into loads for all the elements
first and then the lhs into writes to all the elements. This is not efficient, because
it requires the whole set of loads to be alive until we start consuming them with
the writes.
These patches fix this by splitting array and struct copies into multiple
single-element copies so that we generate consecutive loads and stores for each
element, reducing the lifespan of the loads and thus reducing register pressure.
No regressions in dEQP's SSBO functional tests.
Fixes:
spec/arb_shader_storage_buffer_object/execution/large-field-copy.shader_test
spec/arb_shader_storage_buffer_object/linker/copy-large-array.shader_test
Iago Toral Quiroga (2):
glsl/lower_ubo_reference: split array copies into element copies
glsl/lower_ubo_reference: split struct copies into element copies
src/glsl/lower_ubo_reference.cpp | 119 +++++++++++++++++++++++++++++++++++++++
1 file changed, 119 insertions(+)
--
1.9.1
More information about the mesa-dev
mailing list