From 5ecd4520c804a4f3358ea95c57f8c7ffd1d8d7ff Mon Sep 17 00:00:00 2001 From: Nanley Chery Date: Fri, 17 Oct 2025 10:17:45 -0400 Subject: [PATCH] iris: Limit resolves for atomics to R32 formats GL only allows atomics on R32 formats. So, for a shader which does atomic operations, only decompress the bound R32-formatted images instead of every image. Aside from the performance improvement, explicitly limiting the formats here makes it clear which formats may be resolved on gfx12.0. This helps us to limit the scope of the Ys + 3D-dim restriction that will be added in the next patch. Reviewed-by: Rohan Garg Reviewed-by: Lionel Landwerlin Part-of: --- src/gallium/drivers/iris/iris_resolve.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/gallium/drivers/iris/iris_resolve.c b/src/gallium/drivers/iris/iris_resolve.c index 07df4932a23..f7ea7bc8870 100644 --- a/src/gallium/drivers/iris/iris_resolve.c +++ b/src/gallium/drivers/iris/iris_resolve.c @@ -1035,6 +1035,9 @@ iris_image_view_aux_usage(struct iris_context *ice, pview->u.tex.level : 0; bool uses_atomic_load_store = + (pview->format == PIPE_FORMAT_R32_UINT || + pview->format == PIPE_FORMAT_R32_SINT || + pview->format == PIPE_FORMAT_R32_FLOAT) && ice->shaders.uncompiled[info->stage]->uses_atomic_load_store; /* Prior to GFX12, render compression is not supported for images. */