diff --git a/src/asahi/compiler/agx_compile.c b/src/asahi/compiler/agx_compile.c index fb2cc3825c4..b41ce682197 100644 --- a/src/asahi/compiler/agx_compile.c +++ b/src/asahi/compiler/agx_compile.c @@ -3560,6 +3560,8 @@ agx_compile_shader_nir(nir_shader *nir, struct agx_shader_key *key, info->reads_tib = nir->info.fs.uses_fbfetch_output; info->early_fragment_tests = nir->info.fs.early_fragment_tests; + } else if (nir->info.stage == MESA_SHADER_COMPUTE) { + info->imageblock_stride = nir->info.cs.image_block_size_per_thread_agx; } out->binary = binary.data; diff --git a/src/asahi/compiler/agx_compile.h b/src/asahi/compiler/agx_compile.h index c65e2836996..eb5a9500dc2 100644 --- a/src/asahi/compiler/agx_compile.h +++ b/src/asahi/compiler/agx_compile.h @@ -73,6 +73,9 @@ struct agx_shader_info { /* Local memory allocation in bytes */ unsigned local_size; + /* Local imageblock allocation in bytes per thread */ + unsigned imageblock_stride; + /* Scratch memory allocation in bytes for main/preamble respectively */ unsigned scratch_size, preamble_scratch_size;