radeonsi: re-enable non-TC-compatible HTILE for write-only Z/S

It caused the Blender corruption, but the previous commit likely fixes it.

The workaround regressed performance for Furmark and Plot3D with 8xMSAA.

If you want to enable the workaround again in the future, just add this
line back: sscreen->info.gfx_level >= GFX11 ||

Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32885>
This commit is contained in:
Marek Olšák
2025-01-03 23:48:45 -05:00
committed by Marge Bot
parent 75a03d733a
commit d9dd485c02

View File

@@ -1148,20 +1148,17 @@ static struct si_texture *si_texture_create_object(struct pipe_screen *screen,
tex->depth_clear_value[i] = 1.0;
if (tex->surface.flags & RADEON_SURF_TC_COMPATIBLE_HTILE) {
assert(sscreen->info.gfx_level < GFX12);
/* On GFX8, HTILE uses different tiling depending on the TC_COMPATIBLE_HTILE
* setting, so we have to enable it if we enabled it at allocation.
*
* GFX11 has Z corruption if we don't enable TC-compatible HTILE, see:
* https://gitlab.freedesktop.org/mesa/mesa/-/issues/11891
*
* GFX9 and later use the same tiling for both, so TC-compatible HTILE can be
* GFX9+ and later use the same tiling for both, so TC-compatible HTILE can be
* enabled on demand.
*/
tex->tc_compatible_htile = sscreen->info.gfx_level == GFX8 ||
sscreen->info.gfx_level >= GFX11 ||
/* Mipmapping always starts TC-compatible. */
(sscreen->info.gfx_level >= GFX9 &&
sscreen->info.gfx_level < GFX11 &&
tex->buffer.b.b.last_level > 0);
}