diff options
author | Rob Clark <[email protected]> | 2014-02-01 10:53:00 -0500 |
---|---|---|
committer | Rob Clark <[email protected]> | 2014-02-01 12:10:17 -0500 |
commit | dc00ec154bda15672861d1b508aa4aacdb306f68 (patch) | |
tree | 0fb6c1ab574d518b30e5a11910f5f81889830c13 /src/gallium/drivers/freedreno/freedreno_gmem.c | |
parent | 1fe9df8f29106013f5b6e4407b4877f6bf3b493d (diff) |
freedreno: better manage our WFI's
Updates to non-banked registers, CP_LOAD_STATE, etc, need a WFI if there
is potentially pending rendering. Track this better, and add fd_wfi()
calls everywhere that might potentially need CP_WAIT_FOR_IDLE.
Signed-off-by: Rob Clark <[email protected]>
Diffstat (limited to 'src/gallium/drivers/freedreno/freedreno_gmem.c')
-rw-r--r-- | src/gallium/drivers/freedreno/freedreno_gmem.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/gallium/drivers/freedreno/freedreno_gmem.c b/src/gallium/drivers/freedreno/freedreno_gmem.c index 6a55aa4c133..80cf7c89c6f 100644 --- a/src/gallium/drivers/freedreno/freedreno_gmem.c +++ b/src/gallium/drivers/freedreno/freedreno_gmem.c @@ -278,6 +278,7 @@ render_tiles(struct fd_context *ctx) /* emit IB to drawcmds: */ OUT_IB(ctx->ring, ctx->draw_start, ctx->draw_end); + fd_reset_wfi(ctx); /* emit gmem2mem to transfer tile back to system memory: */ ctx->emit_tile_gmem2mem(ctx, tile); @@ -291,6 +292,7 @@ render_sysmem(struct fd_context *ctx) /* emit IB to drawcmds: */ OUT_IB(ctx->ring, ctx->draw_start, ctx->draw_end); + fd_reset_wfi(ctx); } void @@ -314,6 +316,8 @@ fd_gmem_render_tiles(struct pipe_context *pctx) fd_ringmarker_mark(ctx->draw_end); fd_ringmarker_mark(ctx->binning_end); + fd_reset_wfi(ctx); + ctx->stats.batch_total++; if (sysmem) { @@ -339,7 +343,7 @@ fd_gmem_render_tiles(struct pipe_context *pctx) fd_ringmarker_mark(ctx->draw_start); fd_ringmarker_mark(ctx->binning_start); - fd_reset_rmw_state(ctx); + fd_reset_wfi(ctx); /* update timestamps on render targets: */ timestamp = fd_ringbuffer_timestamp(ctx->ring); |