Mesa (master): radeonsi/compute: Clamp COMPUTE_TMPRING_SIZE.WAVES to: num_cu * 32
Tom Stellard
tstellar at kemper.freedesktop.org
Mon Dec 8 23:35:48 UTC 2014
Module: Mesa
Branch: master
Commit: c16436149c1ca78f86ba992977fe6083b732bc1d
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=c16436149c1ca78f86ba992977fe6083b732bc1d
Author: Tom Stellard <thomas.stellard at amd.com>
Date: Fri Dec 5 23:59:11 2014 +0000
radeonsi/compute: Clamp COMPUTE_TMPRING_SIZE.WAVES to: num_cu * 32
This is the maximum value allowed for this field.
---
src/gallium/drivers/radeonsi/si_compute.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/src/gallium/drivers/radeonsi/si_compute.c b/src/gallium/drivers/radeonsi/si_compute.c
index 6ddb478..bf935dc 100644
--- a/src/gallium/drivers/radeonsi/si_compute.c
+++ b/src/gallium/drivers/radeonsi/si_compute.c
@@ -371,6 +371,9 @@ static void si_launch_grid(
| S_00B85C_SH1_CU_EN(0xffff /* Default value */))
;
+ num_waves_for_scratch =
+ MIN2(num_waves_for_scratch,
+ 32 * sctx->screen->b.info.max_compute_units);
si_pm4_set_reg(pm4, R_00B860_COMPUTE_TMPRING_SIZE,
/* The maximum value for WAVES is 32 * num CU.
* If you program this value incorrectly, the GPU will hang if
More information about the mesa-commit
mailing list