[Mesa-dev] [PATCH v3 00/17] panfrost: Support batch pipelining

Alyssa Rosenzweig alyssa at rosenzweig.io
Fri Sep 20 21:11:38 UTC 2019


Series looks quite good, overall. Just a few minor issues, but probably
not even enough to justify a respin. Congratulations! :p

On Wed, Sep 18, 2019 at 03:24:22PM +0200, Boris Brezillon wrote:
> Hello,
> 
> This is the third attempt at supporting batch pipelining. This time I
> implemented it using a dependency graph (as suggested by Alyssa and
> Steven) so that batch submission can be delayed even more: the only
> time we flush batches now is when we have an explicit flush or when
> the CPU needs to access a BO (we might want to tweak that a bit to
> avoid the extra latency incurred by this solution). With that in place
> we hope to increase GPU utilization.
> 
> Patches 15 and 16 are optional, but I remember reading (I think it was
> Steven who mentioned that) that draw order matters when queueing render
> operations for different frames (frame N should ideally be ready before
> frame N+1). Not sure if enforcing draw call order is enough to guarantee
> that rendering of frame N always finishes before frame N+1 though.
> If that's something you don't want to merge, I can drop it.
> 
> Regards,
> 
> Boris
> 
> Boris Brezillon (17):
>   panfrost: Extend the panfrost_batch_add_bo() API to pass access flags
>   panfrost: Make panfrost_batch->bos a hash table
>   panfrost: Add a batch fence
>   panfrost: Use the per-batch fences to wait on the last submitted batch
>   panfrost: Add a panfrost_freeze_batch() helper
>   panfrost: Start tracking inter-batch dependencies
>   panfrost: Prepare panfrost_fence for batch pipelining
>   panfrost: Add a panfrost_flush_all_batches() helper
>   panfrost: Add a panfrost_flush_batches_accessing_bo() helper
>   panfrost: Kill the explicit serialization in panfrost_batch_submit()
>   panfrost: Get rid of the flush in panfrost_set_framebuffer_state()
>   panfrost: Add flags to reflect the BO imported/exported state
>   panfrost: Make sure the BO is 'ready' when picked from the cache
>   panfrost: Do fine-grained flushing when preparing BO for CPU accesses
>   panfrost: Rename ctx->batches into ctx->fbo_to_batch
>   panfrost: Take draw call order into account
>   panfrost/ci: New tests are passing
> 
>  .../drivers/panfrost/ci/expected-failures.txt |   4 -
>  src/gallium/drivers/panfrost/pan_allocate.c   |  14 +-
>  src/gallium/drivers/panfrost/pan_blend_cso.c  |   6 +-
>  src/gallium/drivers/panfrost/pan_bo.c         | 116 ++-
>  src/gallium/drivers/panfrost/pan_bo.h         |  44 ++
>  src/gallium/drivers/panfrost/pan_compute.c    |   2 +-
>  src/gallium/drivers/panfrost/pan_context.c    | 121 ++--
>  src/gallium/drivers/panfrost/pan_context.h    |  15 +-
>  src/gallium/drivers/panfrost/pan_instancing.c |   5 +-
>  src/gallium/drivers/panfrost/pan_job.c        | 668 ++++++++++++++++--
>  src/gallium/drivers/panfrost/pan_job.h        |  58 +-
>  src/gallium/drivers/panfrost/pan_resource.c   |  27 +-
>  src/gallium/drivers/panfrost/pan_screen.c     |  65 +-
>  src/gallium/drivers/panfrost/pan_screen.h     |   3 +-
>  src/gallium/drivers/panfrost/pan_varyings.c   |  10 +-
>  15 files changed, 956 insertions(+), 202 deletions(-)
> 
> -- 
> 2.21.0


More information about the mesa-dev mailing list