mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 18:18:06 +02:00
ir3: Fix barrier error case calculation
Make waves_per_wg actually be the waves per workgroup, so that the condition below for when we should error out actually is correct. Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/39463>
This commit is contained in:
parent
f3c53cf66b
commit
b95839b9c9
1 changed files with 3 additions and 3 deletions
|
|
@ -277,15 +277,15 @@ ir3_get_reg_independent_max_waves(struct ir3_shader_variant *v,
|
|||
unsigned waves_per_wg =
|
||||
DIV_ROUND_UP(threads_per_wg, compiler->info->threadsize_base *
|
||||
(double_threadsize ? 2 : 1) *
|
||||
compiler->info->wave_granularity);
|
||||
compiler->info->wave_granularity) *
|
||||
compiler->info->wave_granularity;
|
||||
|
||||
/* Shared is allocated in chunks of 1k */
|
||||
unsigned shared_per_wg = ALIGN_POT(v->shared_size, 1024);
|
||||
if (shared_per_wg > 0 && !v->local_size_variable) {
|
||||
unsigned wgs_per_core = compiler->info->cs_shared_mem_size / shared_per_wg;
|
||||
|
||||
max_waves = MIN2(max_waves, waves_per_wg * wgs_per_core *
|
||||
compiler->info->wave_granularity);
|
||||
max_waves = MIN2(max_waves, waves_per_wg * wgs_per_core);
|
||||
}
|
||||
|
||||
/* If we have a compute shader that has a big workgroup, a barrier, and
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue