Module: Mesa
Branch: master
Commit: 5da84a7e120d1df848531c6e7eb60340ac4dc43c
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=5da84a7e120d1df848531c6e7eb60340ac4dc43c

Author: Kenneth Graunke <kenn...@whitecape.org>
Date:   Wed Nov 23 12:24:22 2016 -0800

i965: Fix a mistake from porting the URB allocation code to arrays.

Commit 6d416bcd846a49414f210cd761789156c37a7b3e (i965: Use arrays in
Gen7+ URB code.) introduced a regression which caused us to fail to
allocate all of our URB space.

   -         total_wants -= ds_wants;
   +         total_wants -= additional;

The new line should have been total_wants -= wants[i].

Fixes a large performance regression in TessMark.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=98815
Signed-off-by: Kenneth Graunke <kenn...@whitecape.org>
Reviewed-by: Matt Turner <matts...@gmail.com>

---

 src/intel/common/gen_urb_config.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/intel/common/gen_urb_config.c 
b/src/intel/common/gen_urb_config.c
index c925a0d..937163b 100644
--- a/src/intel/common/gen_urb_config.c
+++ b/src/intel/common/gen_urb_config.c
@@ -160,7 +160,7 @@ gen_get_urb_config(const struct gen_device_info *devinfo,
             roundf(wants[i] * (((float) remaining_space) / total_wants));
          chunks[i] += additional;
          remaining_space -= additional;
-         total_wants -= additional;
+         total_wants -= wants[i];
       }
 
       chunks[MESA_SHADER_GEOMETRY] += remaining_space;

_______________________________________________
mesa-commit mailing list
mesa-commit@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-commit

Reply via email to