Zen tuning part 2: Increase branch_cost to 3

Jan Hubicka hubicka@ucw.cz
Thu Oct 5 15:11:00 GMT 2017


Hi,
this patch increases branch_cost to 3.  Constant 2 is apparently copied from
bdver4 costs while core and generic use 3.  3 seems to give best results for
spec2000 and also significantly improve monte carlo benchmark from scimark.

Bootstrapped/regtested x86_64-linux, comitted.

Index: config/i386/i386.c
===================================================================
--- config/i386/i386.c	(revision 253448)
+++ config/i386/i386.c	(working copy)
@@ -1421,7 +1421,7 @@ struct processor_costs znver1_cost = {
      to limit number of prefetches at all, as their execution also takes some
      time).  */
   100,					/* number of parallel prefetches.  */
-  2,					/* Branch cost.  */
+  3,					/* Branch cost.  */
   COSTS_N_INSNS (6),			/* cost of FADD and FSUB insns.  */
   COSTS_N_INSNS (6),			/* cost of FMUL instruction.  */
   COSTS_N_INSNS (42),			/* cost of FDIV instruction.  */



More information about the Gcc-patches mailing list