diff options
author | Marek Olšák <[email protected]> | 2014-12-30 23:49:59 +0100 |
---|---|---|
committer | Marek Olšák <[email protected]> | 2015-01-07 12:06:43 +0100 |
commit | 9141d8855555e45a057970e78969e1518ad3617d (patch) | |
tree | ac48f03712634f6dfd47c8f2a8081790ca25f3ef /src/gallium/drivers/radeonsi/si_pm4.c | |
parent | 1b82eb677de63ec49f56800b81ac49b79fc5576a (diff) |
radeonsi: reduce the size of si_pm4_state
- the relocs array is unused, remove it
- ndw is at most 115 (init), set 140 as the maximum
- compute needs 4 buffers per state, graphics only needs 1; set 4 as the maximum
Reviewed-by: Michel Dänzer <[email protected]>
Diffstat (limited to 'src/gallium/drivers/radeonsi/si_pm4.c')
-rw-r--r-- | src/gallium/drivers/radeonsi/si_pm4.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/src/gallium/drivers/radeonsi/si_pm4.c b/src/gallium/drivers/radeonsi/si_pm4.c index 954eb6e5ff1..21ab9f24b21 100644 --- a/src/gallium/drivers/radeonsi/si_pm4.c +++ b/src/gallium/drivers/radeonsi/si_pm4.c @@ -145,17 +145,13 @@ unsigned si_pm4_dirty_dw(struct si_context *sctx) void si_pm4_emit(struct si_context *sctx, struct si_pm4_state *state) { struct radeon_winsys_cs *cs = sctx->b.rings.gfx.cs; + for (int i = 0; i < state->nbo; ++i) { r600_context_bo_reloc(&sctx->b, &sctx->b.rings.gfx, state->bo[i], state->bo_usage[i], state->bo_priority[i]); } memcpy(&cs->buf[cs->cdw], state->pm4, state->ndw * 4); - - for (int i = 0; i < state->nrelocs; ++i) { - cs->buf[cs->cdw + state->relocs[i]] += cs->cdw << 2; - } - cs->cdw += state->ndw; #if SI_TRACE_CS |