From 4bf29d15f2e01348a45a1f4e1a135962f123fdd6 Mon Sep 17 00:00:00 2001 From: Wilco Dijkstra Date: Tue, 19 Nov 2019 15:57:54 +0000 Subject: [PATCH] [AArch64] PR79262: Adjust vector cost PR79262 has been fixed for almost all AArch64 cpus, however the example is still vectorized in a few cases, resulting in lower performance. Adjust the vector cost slightly so that so that -mcpu=cortex-a53 now has identical performance as -mcpu=cortex-a57 on libquantum. gcc/ PR target/79262 * config/aarch64/aarch64.c (generic_vector_cost): Adjust vec_to_scalar_cost. From-SVN: r278452 --- gcc/ChangeLog | 6 ++++++ gcc/config/aarch64/aarch64.c | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 7dc1d93f0b7..b36834bf475 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -4,6 +4,12 @@ (toplev::main): ... here as we need init_options_struct being called. +2019-11-19 Wilco Dijkstra + + PR target/79262 + * config/aarch64/aarch64.c (generic_vector_cost): Adjust + vec_to_scalar_cost. + 2019-11-19 Wilco Dijkstra * config/arm/arm-cpus.in (armv7): Set tune to Cortex-A53. diff --git a/gcc/config/aarch64/aarch64.c b/gcc/config/aarch64/aarch64.c index f710aa2e795..94e664af52f 100644 --- a/gcc/config/aarch64/aarch64.c +++ b/gcc/config/aarch64/aarch64.c @@ -447,7 +447,7 @@ static const struct cpu_vector_cost generic_vector_cost = 1, /* vec_int_stmt_cost */ 1, /* vec_fp_stmt_cost */ 2, /* vec_permute_cost */ - 1, /* vec_to_scalar_cost */ + 2, /* vec_to_scalar_cost */ 1, /* scalar_to_vec_cost */ 1, /* vec_align_load_cost */ 1, /* vec_unalign_load_cost */ -- 2.30.2