Hi all,

This patch gets the aarch64 backend to use the Cortex A53 costs when tuning for that core, instead of using the generic costs. The costs table itself was added recently in arm/aarch-cost-tables.h and is shared between the two ports.

Tested aarch64-none-elf on a model.

Ok for trunk?

Thanks,
Kyrill

2013-11-25  Kyrylo Tkachov  <kyrylo.tkac...@arm.com>

    * config/aarch64/aarch64.c (cortexa53_tuning): New struct.
    * config/aarch64/aarch64-cores.def (cortex-a53):
    Use cortexa53 tuning struct.
diff --git a/gcc/config/aarch64/aarch64-cores.def b/gcc/config/aarch64/aarch64-cores.def
index 51c1ff8..b631dbe 100644
--- a/gcc/config/aarch64/aarch64-cores.def
+++ b/gcc/config/aarch64/aarch64-cores.def
@@ -34,5 +34,5 @@
    This list currently contains example CPUs that implement AArch64, and
    therefore serves as a template for adding more CPUs in the future.  */
 
-AARCH64_CORE("cortex-a53",	  cortexa53,	     8,  AARCH64_FL_FPSIMD,    generic)
+AARCH64_CORE("cortex-a53",	  cortexa53,	     8,  AARCH64_FL_FPSIMD,    cortexa53)
 AARCH64_CORE("cortex-a57",	  cortexa15,	     8,  AARCH64_FL_FPSIMD,    generic)
diff --git a/gcc/config/aarch64/aarch64.c b/gcc/config/aarch64/aarch64.c
index aad9a29..95432976 100644
--- a/gcc/config/aarch64/aarch64.c
+++ b/gcc/config/aarch64/aarch64.c
@@ -214,6 +214,15 @@ static const struct tune_params generic_tunings =
   NAMED_PARAM (memmov_cost, 4)
 };
 
+static const struct tune_params cortexa53_tunings =
+{
+  &cortexa53_extra_costs,
+  &generic_addrcost_table,
+  &generic_regmove_cost,
+  &generic_vector_cost,
+  NAMED_PARAM (memmov_cost, 4)
+};
+
 /* A processor implementing AArch64.  */
 struct processor
 {

Reply via email to