v3dv: add the concept of a job
authorIago Toral Quiroga <itoral@igalia.com>
Wed, 8 Jan 2020 10:14:35 +0000 (11:14 +0100)
committerMarge Bot <eric+marge@anholt.net>
Tue, 13 Oct 2020 21:21:26 +0000 (21:21 +0000)
commit5259175fe86547ccb8f6598498b64d3b8ab45953
treef6a207cc53748f79c76bde24a2ed4545dcfc7491
parentaef5a5cbca7715799d998b63c31cb86f5b5478a8
v3dv: add the concept of a job

As we make progress towards more complex submissions we will need to split
our command buffers into smaller executable units (jobs) that we can
submit indepdently to the kernel. This will be required to implement
pipeline barriers, split subpasses that have depedencies on previous
subpasses, split render passes that use more than 4 render targets, etc.

For now we keep things simple and we only keep one job as current
recording target in the command buffer, and we generate a new one
with every subpass or with any commands we see outside of a render pass
(only vkCopyImageToBuffer for now). In the future we probably want to
optimize this by merging subpasses into the same job when possible,
etc.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6766>
src/broadcom/vulkan/v3dv_cl.c
src/broadcom/vulkan/v3dv_cl.h
src/broadcom/vulkan/v3dv_cmd_buffer.c
src/broadcom/vulkan/v3dv_meta_copy.c
src/broadcom/vulkan/v3dv_private.h
src/broadcom/vulkan/v3dv_queue.c
src/broadcom/vulkan/v3dv_uniforms.c