agx: plumb imageblock stride

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30633>
This commit is contained in:
Alyssa Rosenzweig 2024-08-07 13:07:38 -04:00
parent b9eff53daa
commit 9b39c5427f
2 changed files with 5 additions and 0 deletions

View file

@ -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;

View file

@ -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;