Vivante hardware exhibits floating-point interpolation inconsistencies
at the diagonal seam when the blitter uses a two-triangle quad for scaled
NEAREST blits. Enable the single-triangle blitter mode to match the
proprietary driver's approach of using one oversized triangle
clipped by scissor.
Fixes dEQP-GLES3.functional.fbo.blit.rect.nearest_consistency_mag_*
Fixes dEQP-GLES3.functional.fbo.blit.rect.nearest_consistency_min_*
Signed-off-by: Christian Gmeiner <cgmeiner@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/39973>
When the blitter draws a textured quad using two triangles, the
interpolation at the diagonal seam between triangles can produce
slightly different texture coordinates for the same pixel position.
For NEAREST filtering this causes inconsistent texel selection at the
seam boundary, failing dEQP-GLES3 nearest_consistency_* tests.
V3D already works around a similar issue by reordering triangle indices
(use_index_buffer), but Vivante GPUs requires a stronger fix: drawing a
single oversized triangle and relying on scissor to clip to the actual
destination rectangle. This matches the approach used by Vivante's
proprietary driver.
Add a new use_single_triangle flag to blitter_context that drivers can
opt-in.
Signed-off-by: Christian Gmeiner <cgmeiner@igalia.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/39973>
Quantization maps cannot work with cu_qp_delta_enabled = 1, and VCN1 is
unlikely to ever support it.
See 1dda9d56cb ("radv/video: Disable rate control modes for H265 encode on VCN1")
for additional details.
Reviewed-by: Ruijing Dong <ruijing.dong@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40052>
Originally, I thought I could get away with not doing this because we
were sizing up the framebuffer boundary to include the superblocks.
However, that's not actually good enough because it's not just about
when we do a clear. It's actually required for AFBC writes to work
properly with small tiles.
Fixes: 6a56d35705 ("pan/fb: Fill out our own descriptors")
Reviewed-by: Christoph Pillmayer <christoph.pillmayer@arm.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/39324>
When the the tile size is not a multiple of a superblock for the given
render target, there's a potential race condition between the write at
the end of one tile and reads in some other tile where the reads may
access a superblock in a partially updated state. If the tile size is a
multiple of a superblock, this shouldn't happen because no superblock is
ever used by more than one tile. But for small tiles, this can happen.
The hardware provides us an escape hatch: the reverse_issue_order bit.
This bit comes with a bit of a performance cost but it's necessary to
ensure rendering correctness.
Fixes: 6a56d35705 ("pan/fb: Fill out our own descriptors")
Reviewed-by: Christoph Pillmayer <christoph.pillmayer@arm.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/39324>
Every time we need to adjust what goes to these helpers, it's a giant
pain because of all the function prototypes and the mode table. Just
put everything in a struct and pass that around.
Reviewed-by: Christoph Pillmayer <christoph.pillmayer@arm.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/39324>
VK_IMAGE_LAYOUT_PREINITIALIZED is only well defined for linear images
in Vulkan, and linear images can't have DCC. So, this was dead code.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40070>
Dependencies in UNDEFs were already not propagated by
update_inst_scoreboard(), since the instruction there
was not consider neither ordered or unordered; and also
not being used to resolve implicit dependencies.
The generator was already ignoring any baked dependency
but for cases where UNDEF had two dependencies, a sync nop
would be generated -- which would be redundant with a
later sync nop.
Since we know UNDEFs have no dependencies, stop treating
them specially when trimming dependencies.
This patch remove this particular class of redundant sync nops.
No functional change is expected.
Reviewed-by: Francisco Jerez <currojerez@riseup.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/39875>
These changes to the nightly results were missed. We're now passing one
more test, and the trace renders ever so slightly differently. The
differences doesn't seem to suggest anything wrong, so let's just accept
the change.
Fixes: 399c0d22f3 ("panfrost: blending fixes for Midgard")
Acked-by: Eric R. Smith <eric.smith@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40090>