===================================================================
@@ -288,4 +288,7 @@ extern bool arm_autoinc_modes_ok_p (enum machine_m
extern void arm_emit_eabi_attribute (const char *, int, int);
+extern bool arm_branch_cost (bool, bool);
+extern bool arm_logical_op_non_short_circuit (void);
+
#endif /* ! GCC_ARM_PROTOS_H */
===================================================================
@@ -30351,4 +30351,19 @@ arm_asan_shadow_offset (void)
return (unsigned HOST_WIDE_INT) 1 << 29;
}
+/* Implement BRANCH_COST as a function, to hide tune_params from the
+ rest of the compiler. */
+bool
+arm_branch_cost (bool speed_p, bool predictable_p)
+{
+ return current_tune->branch_cost (speed_p, predictable_p);
+}
+
+/* Likewise for LOGICAL_OP_NON_SHORT_CIRCUIT. */
+bool
+arm_logical_op_non_short_circuit (void)
+{
+ return (current_tune->logical_op_non_short_circuit[TARGET_ARM]);
+}
+
#include "gt-arm.h"
===================================================================
@@ -2042,14 +2042,13 @@ enum arm_auto_incmodes
/* Try to generate sequences that don't involve branches, we can then use
conditional instructions. */
#define BRANCH_COST(speed_p, predictable_p) \
- (current_tune->branch_cost (speed_p, predictable_p))
+ arm_branch_cost (speed_p, predictable_p)
/* False if short circuit operation is preferred. */
#define LOGICAL_OP_NON_SHORT_CIRCUIT \
((optimize_size) \
? (TARGET_THUMB ? false : true) \
- : (current_tune->logical_op_non_short_circuit[TARGET_ARM]))
-
+ : arm_logical_op_non_short_circuit ()
/* Position Independent Code. */
/* We decide which register to use based on the compilation options and
===================================================================
@@ -22,9 +22,6 @@ along with GCC; see the file COPYING3. If not see
#include "system.h"
#include "coretypes.h"
#include "tm.h"
-/* rtl is needed only because arm back-end requires it for
- BRANCH_COST. */
-#include "rtl.h"
#include "tm_p.h"
#include "tree.h"
#include "basic-block.h"
===================================================================
@@ -23,7 +23,6 @@ along with GCC; see the file COPYING3. If not see
#include "coretypes.h"
#include "hash-table.h"
#include "tm.h"
-#include "rtl.h"
#include "tm_p.h"
#include "tree.h"
#include "basic-block.h"