panfrost: Don't add the tiler BO when it's not accessed

Only batches involving the tiler block need to add the tiler heap to the
list of accessed BOs. While at it, clarify who's accessing this heap.

Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Tested-by: Icecream95 <ixn@disroot.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8822>
This commit is contained in:
Boris Brezillon
2021-02-03 08:44:03 +01:00
parent 66125c429f
commit 7ecb2eaf26
+6 -3
View File
@@ -982,9 +982,12 @@ panfrost_batch_submit_ioctl(struct panfrost_batch *batch,
panfrost_pool_get_bo_handles(&batch->invisible_pool, bo_handles + submit.bo_handle_count);
submit.bo_handle_count += panfrost_pool_num_bos(&batch->invisible_pool);
/* Used by all tiler jobs, and occasionally by fragment jobs.
* (XXX: skip for compute-only) */
bo_handles[submit.bo_handle_count++] = dev->tiler_heap->gem_handle;
/* Add the tiler heap to the list of accessed BOs if the batch has at
* least one tiler job. Tiler heap is written by tiler jobs and read
* by fragment jobs (the polygon list is coming from this heap).
*/
if (batch->scoreboard.first_tiler)
bo_handles[submit.bo_handle_count++] = dev->tiler_heap->gem_handle;
submit.bo_handles = (u64) (uintptr_t) bo_handles;
if (ctx->is_noop)