From 37598898463fa8057db4efe01c2b8b639dc1a221 Mon Sep 17 00:00:00 2001 From: Rob Clark Date: Thu, 26 Dec 2024 14:43:13 -0800 Subject: [PATCH] freedreno/a6xx: Align lrz height to 32 Emperically this seems to be required when doing a linear clear of the tiled LRZ buffer (because height needs to match aligned height for a linear clear to dtrt). Issue could be reproduced with nolrzfc and: glmark2 -s 1472x920 --visual-config samples=2 -b terrain Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/12336 Fixes: a127a7854872 ("freedreno: Re-enable LRZ for a7xx") Signed-off-by: Rob Clark Part-of: --- src/gallium/drivers/freedreno/a6xx/fd6_resource.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gallium/drivers/freedreno/a6xx/fd6_resource.cc b/src/gallium/drivers/freedreno/a6xx/fd6_resource.cc index 28c7dc649fa..f01fc4d0dd1 100644 --- a/src/gallium/drivers/freedreno/a6xx/fd6_resource.cc +++ b/src/gallium/drivers/freedreno/a6xx/fd6_resource.cc @@ -250,7 +250,7 @@ setup_lrz(struct fd_resource *rsc) } unsigned lrz_pitch = align(DIV_ROUND_UP(width, 8), 32); - unsigned lrz_height = align(DIV_ROUND_UP(height, 8), 16); + unsigned lrz_height = align(DIV_ROUND_UP(height, 8), 32); rsc->lrz_height = lrz_height; rsc->lrz_width = lrz_pitch;