summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorolegendo <olegendo@138bc75d-0d04-0410-961f-82ee72b054a4>2014-10-16 13:17:12 +0000
committerolegendo <olegendo@138bc75d-0d04-0410-961f-82ee72b054a4>2014-10-16 13:17:12 +0000
commit9cbd111807a2db06413ff6457bd89433af80474e (patch)
tree48476d9562c94ca95144941fbea06b9ead0ae177
parent3f0b08917cc492a23891c712c3679a62ac025d23 (diff)
downloadgcc-9cbd111807a2db06413ff6457bd89433af80474e.tar.gz
gcc/
* config/sh/sh-protos.h (fldi_ok): Remove. * config/sh/sh.c (fldi_ok): Likewise. (sh_secondary_reload): Don't use fldi_ok. * config/sh/constraints.md (G constraint, H constraint): Don't use fldi_ok. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@216320 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r--gcc/ChangeLog8
-rw-r--r--gcc/config/sh/constraints.md4
-rw-r--r--gcc/config/sh/sh-protos.h1
-rw-r--r--gcc/config/sh/sh.c16
4 files changed, 11 insertions, 18 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index f1754b47107..ffef98259b9 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,11 @@
+2014-10-16 Oleg Endo <olegendo@gcc.gnu.org>
+
+ * config/sh/sh-protos.h (fldi_ok): Remove.
+ * config/sh/sh.c (fldi_ok): Likewise.
+ (sh_secondary_reload): Don't use fldi_ok.
+ * config/sh/constraints.md (G constraint, H constraint): Don't use
+ fldi_ok.
+
2014-10-16 Martin Liska <mliska@suse.cz>
* ipa-icf.c (sem_item_optimizer::process_cong_reduction):
diff --git a/gcc/config/sh/constraints.md b/gcc/config/sh/constraints.md
index e75acfd6900..0e719201bc8 100644
--- a/gcc/config/sh/constraints.md
+++ b/gcc/config/sh/constraints.md
@@ -210,12 +210,12 @@
(define_constraint "G"
"Double constant 0."
(and (match_code "const_double")
- (match_test "fp_zero_operand (op) && fldi_ok ()")))
+ (match_test "fp_zero_operand (op)")))
(define_constraint "H"
"Double constant 1."
(and (match_code "const_double")
- (match_test "fp_one_operand (op) && fldi_ok ()")))
+ (match_test "fp_one_operand (op)")))
;; Extra constraints
(define_constraint "Q"
diff --git a/gcc/config/sh/sh-protos.h b/gcc/config/sh/sh-protos.h
index c12a8964d7e..ca007b9093c 100644
--- a/gcc/config/sh/sh-protos.h
+++ b/gcc/config/sh/sh-protos.h
@@ -191,7 +191,6 @@ extern void sh_expand_prologue (void);
extern void sh_expand_epilogue (bool);
extern void sh_set_return_address (rtx, rtx);
extern int initial_elimination_offset (int, int);
-extern bool fldi_ok (void);
extern bool sh_hard_regno_rename_ok (unsigned int, unsigned int);
extern bool sh_cfun_interrupt_handler_p (void);
extern bool sh_cfun_resbank_handler_p (void);
diff --git a/gcc/config/sh/sh.c b/gcc/config/sh/sh.c
index 065ac265fee..288a955dee7 100644
--- a/gcc/config/sh/sh.c
+++ b/gcc/config/sh/sh.c
@@ -9875,19 +9875,6 @@ fp_one_operand (rtx op)
return REAL_VALUES_EQUAL (r, dconst1);
}
-/* In general mode switching is used. If we are
- compiling without -mfmovd, movsf_ie isn't taken into account for
- mode switching. We could check in machine_dependent_reorg for
- cases where we know we are in single precision mode, but there is
- interface to find that out during reload, so we must avoid
- choosing an fldi alternative during reload and thus failing to
- allocate a scratch register for the constant loading. */
-bool
-fldi_ok (void)
-{
- return true;
-}
-
/* Return the TLS type for TLS symbols. */
enum tls_model
tls_symbolic_operand (rtx op, enum machine_mode mode ATTRIBUTE_UNUSED)
@@ -13106,8 +13093,7 @@ sh_secondary_reload (bool in_p, rtx x, reg_class_t rclass_i,
if (REGCLASS_HAS_FP_REG (rclass)
&& ! TARGET_SHMEDIA
&& immediate_operand ((x), mode)
- && ! ((fp_zero_operand (x) || fp_one_operand (x))
- && mode == SFmode && fldi_ok ()))
+ && ! ((fp_zero_operand (x) || fp_one_operand (x)) && mode == SFmode))
switch (mode)
{
case SFmode: