aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorMaxim Kuvyrkov <maxim.kuvyrkov@linaro.org>2015-01-17 01:06:17 +0000
committerMaxim Kuvyrkov <mkuvyrkov@gcc.gnu.org>2015-01-17 01:06:17 +0000
commitd03f7e440b3197e16e57282392233899e557e6f2 (patch)
tree2b95f6ab2dd3441b6b44fa9429f314f49bed18c0 /gcc
parent25d1a5a74d172683fac3e62816ff0aef8ad3b379 (diff)
downloadgcc-d03f7e440b3197e16e57282392233899e557e6f2.zip
gcc-d03f7e440b3197e16e57282392233899e557e6f2.tar.gz
gcc-d03f7e440b3197e16e57282392233899e557e6f2.tar.bz2
Enable max_issue for AArch32 and AArch64
Enable max_issue for AArch32 and AArch64 * config/aarch64/aarch64.c (aarch64_sched_first_cycle_multipass_dfa_lookahead): Implement hook. (TARGET_SCHED_FIRST_CYCLE_MULTIPASS_DFA_LOOKAHEAD): Define. * config/arm/arm.c (arm_first_cycle_multipass_dfa_lookahead): Implement hook. (TARGET_SCHED_FIRST_CYCLE_MULTIPASS_DFA_LOOKAHEAD): Define. From-SVN: r219787
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog9
-rw-r--r--gcc/config/aarch64/aarch64.c13
-rw-r--r--gcc/config/arm/arm.c15
3 files changed, 37 insertions, 0 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index aa60d5d..1d20442 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,12 @@
+2015-01-17 Maxim Kuvyrkov <maxim.kuvyrkov@linaro.org>
+
+ * config/aarch64/aarch64.c
+ (aarch64_sched_first_cycle_multipass_dfa_lookahead): Implement hook.
+ (TARGET_SCHED_FIRST_CYCLE_MULTIPASS_DFA_LOOKAHEAD): Define.
+ * config/arm/arm.c
+ (arm_first_cycle_multipass_dfa_lookahead): Implement hook.
+ (TARGET_SCHED_FIRST_CYCLE_MULTIPASS_DFA_LOOKAHEAD): Define.
+
2015-01-17 Alan Modra <amodra@gmail.com>
* cprop.c (do_local_cprop): Disallow replacement of fixed
diff --git a/gcc/config/aarch64/aarch64.c b/gcc/config/aarch64/aarch64.c
index fdb0116..a89bb41 100644
--- a/gcc/config/aarch64/aarch64.c
+++ b/gcc/config/aarch64/aarch64.c
@@ -94,6 +94,7 @@
#include "builtins.h"
#include "rtl-iter.h"
#include "tm-constrs.h"
+#include "sched-int.h"
/* Defined for convenience. */
#define POINTER_BYTES (POINTER_SIZE / BITS_PER_UNIT)
@@ -6499,6 +6500,14 @@ aarch64_sched_issue_rate (void)
return aarch64_tune_params->issue_rate;
}
+static int
+aarch64_sched_first_cycle_multipass_dfa_lookahead (void)
+{
+ int issue_rate = aarch64_sched_issue_rate ();
+
+ return issue_rate > 1 && !sched_fusion ? issue_rate : 0;
+}
+
/* Vectorizer cost model target hooks. */
/* Implement targetm.vectorize.builtin_vectorization_cost. */
@@ -11387,6 +11396,10 @@ aarch64_gen_adjusted_ldpstp (rtx *operands, bool load,
#undef TARGET_SCHED_ISSUE_RATE
#define TARGET_SCHED_ISSUE_RATE aarch64_sched_issue_rate
+#undef TARGET_SCHED_FIRST_CYCLE_MULTIPASS_DFA_LOOKAHEAD
+#define TARGET_SCHED_FIRST_CYCLE_MULTIPASS_DFA_LOOKAHEAD \
+ aarch64_sched_first_cycle_multipass_dfa_lookahead
+
#undef TARGET_TRAMPOLINE_INIT
#define TARGET_TRAMPOLINE_INIT aarch64_trampoline_init
diff --git a/gcc/config/arm/arm.c b/gcc/config/arm/arm.c
index c106843..337a69b 100644
--- a/gcc/config/arm/arm.c
+++ b/gcc/config/arm/arm.c
@@ -268,6 +268,7 @@ static unsigned HOST_WIDE_INT arm_shift_truncation_mask (machine_mode);
static bool arm_macro_fusion_p (void);
static bool arm_cannot_copy_insn_p (rtx_insn *);
static int arm_issue_rate (void);
+static int arm_first_cycle_multipass_dfa_lookahead (void);
static void arm_output_dwarf_dtprel (FILE *, int, rtx) ATTRIBUTE_UNUSED;
static bool arm_output_addr_const_extra (FILE *, rtx);
static bool arm_allocate_stack_slots_for_args (void);
@@ -624,6 +625,10 @@ static const struct attribute_spec arm_attribute_table[] =
#undef TARGET_SCHED_ISSUE_RATE
#define TARGET_SCHED_ISSUE_RATE arm_issue_rate
+#undef TARGET_SCHED_FIRST_CYCLE_MULTIPASS_DFA_LOOKAHEAD
+#define TARGET_SCHED_FIRST_CYCLE_MULTIPASS_DFA_LOOKAHEAD \
+ arm_first_cycle_multipass_dfa_lookahead
+
#undef TARGET_MANGLE_TYPE
#define TARGET_MANGLE_TYPE arm_mangle_type
@@ -27138,6 +27143,16 @@ arm_issue_rate (void)
}
}
+/* Return how many instructions should scheduler lookahead to choose the
+ best one. */
+static int
+arm_first_cycle_multipass_dfa_lookahead (void)
+{
+ int issue_rate = arm_issue_rate ();
+
+ return issue_rate > 1 && !sched_fusion ? issue_rate : 0;
+}
+
const char *
arm_mangle_type (const_tree type)
{