gallium/u_threaded: increase batch size to increase performance
authorMarek Olšák <marek.olsak@amd.com>
Sat, 1 Sep 2018 07:10:27 +0000 (03:10 -0400)
committerMarek Olšák <marek.olsak@amd.com>
Tue, 4 Sep 2018 18:31:56 +0000 (14:31 -0400)
This reduces mutex overhead.

radeonsi: +4.4% performance with piglit/drawoverhead, DrawElements, Ryzen X1700
iris_dri.so: +14% with piglit/drawoverhead, DrawArrays, i7 7700HQ.

Acked-by: Kenneth Graunke <kenneth@whitecape.org>
src/gallium/auxiliary/util/u_threaded_context.h

index 53c5a7e8c4c8ad5e8f6c806e5a33516d1fc84ed1..be6933d05a4dd6bc64a55fe52da560160c4ae50c 100644 (file)
@@ -220,7 +220,7 @@ struct tc_unflushed_batch_token;
  * The idea is to have batches as small as possible but large enough so that
  * the queuing and mutex overhead is negligible.
  */
-#define TC_CALLS_PER_BATCH    192
+#define TC_CALLS_PER_BATCH    768
 
 /* Threshold for when to use the queue or sync. */
 #define TC_MAX_STRING_MARKER_BYTES  512