This isn't ideal, nor is it required for all descriptor types, but will
work for the time being.
Signed-off-by: Simon Perretta <simon.perretta@imgtec.com>
Acked-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36412>
On cores without gs_rta_support, PBE resolves might depend on writes
that occur within the deferred RTA clears that happen after the PBE
has written.
Since the driver can't know at renderpass creation whether RTA clears
are needed, PBE resolves must be disabled.
Fix for deqp-vk:
dEQP-VK.api.image_clearing.*.clear_color_attachment.multiple_layers.*
Signed-off-by: Jarred Davies <jarred.davies@imgtec.com>
Acked-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36412>
Deferred clears are a way to turn clear operations into transfer operations.
One use of them is to account for multi-layer clears when the HW doesn't
support render targets array.
Fix for deqp:
dEQP-VK.renderpass.dedicated_allocation.attachment_allocation*
Fixes: 9582058 ("pvr: Add deferred RTA clears for cores without gs_rta_support")
Signed-off-by: Luigi Santivetti <luigi.santivetti@imgtec.com>
Acked-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36412>
The maximum width of a texstate is 16k-1; use the highest power of two
(8k) as a fixed width and only adjust the height by the view size.
Signed-off-by: Matt Coster <matt.coster@imgtec.com>
Co-authored-by: Simon Perretta <simon.perretta@imgtec.com>
Acked-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36412>
With the currrent state of things when setting up the texture state
word we need to make sure the swizzle is obtained from a format
compatible with the TPU.
Signed-off-by: Simon Perretta <simon.perretta@imgtec.com>
Co-authored-by: Luigi Santivetti <luigi.santivetti@imgtec.com>
Acked-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36412>
When sharing scratch buffers across framebuffers, it reallocates the scratch
buffer to ensure the smallest scratch buffer is always in use. However, the
check to do this meant that it was possible to end up with a scratch buffer that
was too small, leading to page faults or memory corruption.
Signed-off-by: Frank Binns <frank.binns@imgtec.com>
Acked-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36412>
Factor this step out of pvr_render_pass_setup_load_ops() for keeping
the code more organised and easier to follow.
Signed-off-by: Luigi Santivetti <luigi.santivetti@imgtec.com>
Acked-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36412>
In preparation to add more helpers, rename some function to improve
consistency.
Signed-off-by: Luigi Santivetti <luigi.santivetti@imgtec.com>
Acked-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36412>
The starting offset is always `0` and there isn't really a reason
for why it should be non-zero, we always want to DMA into the
shareds from the beginning, for the load_ops, so removing it.
Signed-off-by: Karmjit Mahil <Karmjit.Mahil@imgtec.com>
Acked-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36412>
To clear up the ambiguity of uncompressed/compressed formats:
- Always use the correct enum type to refer to them, and
- Split the border colour table into two halves so the compressed tex
format enum can be used as an index directly without applying an
offset.
Signed-off-by: Matt Coster <matt.coster@imgtec.com>
Acked-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36412>
Devices with the feature tpu_border_colour_enhanced don't require
e5b9g9r9 formats to be encoded and instead read the channels directly
as f16 values. Without this special handling, two channels were left
uninitialised, leading to random test failures.
Fixes: dEQP-VK.pipeline.monolithic.sampler.view_type.*
.format.e5b9g9r9_ufloat_pack32.address_modes.*_clamp_to_border_*
Signed-off-by: Matt Coster <matt.coster@imgtec.com>
Acked-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36412>