Hi,
  This patch is similar to what I did for ThunderX where I increase
the costs of these instructions slightly to point out there is a
slight cost to using them over using the two instructions.

OK?  Bootstrapped and tested on aarch64-linux-gnu with no regressions.
This gave ~2% on SPEC CPU 2006 int.

Thanks,
Andrew Pinski

ChangeLog:
* config/aarch64/aarch64-cost-tables.h (thunderx2t99_extra_costs):
Increment Arith_shift, Arith_shift_reg, Log_shift, Log_shift_reg and
Extend_arith by 1.
Index: gcc/config/aarch64/aarch64-cost-tables.h
===================================================================
--- gcc/config/aarch64/aarch64-cost-tables.h    (revision 249583)
+++ gcc/config/aarch64/aarch64-cost-tables.h    (working copy)
@@ -239,12 +239,12 @@
     0,                 /* Logical.  */
     0,                 /* Shift.  */
     0,                 /* Shift_reg.  */
-    COSTS_N_INSNS (1), /* Arith_shift.  */
-    COSTS_N_INSNS (1), /* Arith_shift_reg.  */
-    COSTS_N_INSNS (1), /* Log_shift.  */
-    COSTS_N_INSNS (1), /* Log_shift_reg.  */
+    COSTS_N_INSNS (1)+1,       /* Arith_shift.  */
+    COSTS_N_INSNS (1)+1,       /* Arith_shift_reg.  */
+    COSTS_N_INSNS (1)+1,       /* Log_shift.  */
+    COSTS_N_INSNS (1)+1,       /* Log_shift_reg.  */
     0,                 /* Extend.  */
-    COSTS_N_INSNS (1), /* Extend_arith.  */
+    COSTS_N_INSNS (1)+1,       /* Extend_arith.  */
     0,                 /* Bfi.  */
     0,                 /* Bfx.  */
     COSTS_N_INSNS (3), /* Clz.  */

Reply via email to