summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/vc4/vc4_state.c
diff options
context:
space:
mode:
authorEric Anholt <eric@anholt.net>2015-07-28 11:35:03 -0700
committerEric Anholt <eric@anholt.net>2015-10-29 22:58:01 -0700
commit04c42f3ab56a19089b46dea48615aeef8b8225da (patch)
treed9f197e5374846dd31cb9aa755847adddb862298 /src/gallium/drivers/vc4/vc4_state.c
parent06fa2e864acea8f34eb3821523b1924fe8efdc9b (diff)
downloadexternal_mesa3d-04c42f3ab56a19089b46dea48615aeef8b8225da.zip
external_mesa3d-04c42f3ab56a19089b46dea48615aeef8b8225da.tar.gz
external_mesa3d-04c42f3ab56a19089b46dea48615aeef8b8225da.tar.bz2
vc4: Allow user index buffers, to avoid slow readback for shadow IBs.
Improves low-settings openarena performance by 31.9975% +/- 0.659931% (n=7).
Diffstat (limited to 'src/gallium/drivers/vc4/vc4_state.c')
-rw-r--r--src/gallium/drivers/vc4/vc4_state.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gallium/drivers/vc4/vc4_state.c b/src/gallium/drivers/vc4/vc4_state.c
index 1476946..78aa344 100644
--- a/src/gallium/drivers/vc4/vc4_state.c
+++ b/src/gallium/drivers/vc4/vc4_state.c
@@ -305,10 +305,10 @@ vc4_set_index_buffer(struct pipe_context *pctx,
struct vc4_context *vc4 = vc4_context(pctx);
if (ib) {
- assert(!ib->user_buffer);
pipe_resource_reference(&vc4->indexbuf.buffer, ib->buffer);
vc4->indexbuf.index_size = ib->index_size;
vc4->indexbuf.offset = ib->offset;
+ vc4->indexbuf.user_buffer = ib->user_buffer;
} else {
pipe_resource_reference(&vc4->indexbuf.buffer, NULL);
}