mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 13:58:04 +02:00
freedreno: ssbo: keep track if a buffer gets written
Signed-off-by: Christian Gmeiner <christian.gmeiner@gmail.com> Reviewed-by: Rob Clark <robdclark@chromium.org> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/1963>
This commit is contained in:
parent
0ed053f03d
commit
061b262a0c
2 changed files with 3 additions and 0 deletions
|
|
@ -66,6 +66,7 @@ struct fd_constbuf_stateobj {
|
|||
struct fd_shaderbuf_stateobj {
|
||||
struct pipe_shader_buffer sb[PIPE_MAX_SHADER_BUFFERS];
|
||||
uint32_t enabled_mask;
|
||||
uint32_t writable_mask;
|
||||
};
|
||||
|
||||
struct fd_shaderimg_stateobj {
|
||||
|
|
|
|||
|
|
@ -129,6 +129,8 @@ fd_set_shader_buffers(struct pipe_context *pctx,
|
|||
const unsigned modified_bits = u_bit_consecutive(start, count);
|
||||
|
||||
so->enabled_mask &= ~modified_bits;
|
||||
so->writable_mask &= ~modified_bits;
|
||||
so->writable_mask |= writable_bitmask << start;
|
||||
|
||||
for (unsigned i = 0; i < count; i++) {
|
||||
unsigned n = i + start;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue