summaryrefslogtreecommitdiff
path: root/gcc/config/sh
diff options
context:
space:
mode:
authorJoern Rennecke <amylaar@gcc.gnu.org>1996-10-24 01:40:58 +0100
committerJoern Rennecke <amylaar@gcc.gnu.org>1996-10-24 01:40:58 +0100
commitb1bbe7328c3d29e8d3f322837c966da663471d8c (patch)
treedbc1f4046f2265b26b47f0d2fb8d488a903e867d /gcc/config/sh
parentf8d9772e2fc172baf760e9986e4ea4c2c36df42b (diff)
downloadgcc-b1bbe7328c3d29e8d3f322837c966da663471d8c.tar.gz
sh.h (CONST_DOUBLE_OK_FOR_LETTER_P): always true for 'F' .
* sh.h (CONST_DOUBLE_OK_FOR_LETTER_P): always true for 'F' . (LEGITIMATE_CONSTANT_P): accept SFmode and DFmode. From-SVN: r13020
Diffstat (limited to 'gcc/config/sh')
-rw-r--r--gcc/config/sh/sh.h8
1 files changed, 2 insertions, 6 deletions
diff --git a/gcc/config/sh/sh.h b/gcc/config/sh/sh.h
index 2e40b9f0c17..0d7a5c9c7e0 100644
--- a/gcc/config/sh/sh.h
+++ b/gcc/config/sh/sh.h
@@ -576,7 +576,7 @@ extern enum reg_class reg_class_from_letter[];
#define CONST_DOUBLE_OK_FOR_LETTER_P(VALUE, C) \
((C) == 'G' ? fp_zero_operand (VALUE) \
: (C) == 'H' ? fp_one_operand (VALUE) \
- : 0)
+ : (C) == 'F')
/* Given an rtx X being reloaded into a reg required to be
in class CLASS, return the class of reg to actually use.
@@ -907,13 +907,9 @@ extern struct rtx_def *sh_builtin_saveregs ();
/* Nonzero if the constant value X is a legitimate general operand. */
-/* ??? Should modify this to accept CONST_DOUBLE, and then modify the
- constant pool table code to fix loads of CONST_DOUBLEs. If that doesn't
- work well, then we can at least handle simple CONST_DOUBLEs here
- such as 0.0. */
-
#define LEGITIMATE_CONSTANT_P(X) \
(GET_CODE (X) != CONST_DOUBLE \
+ || GET_MODE (X) == DFmode || GET_MODE (X) == SFmode \
|| (TARGET_SH3E && (fp_zero_operand (X) || fp_one_operand (X))))
/* The macros REG_OK_FOR..._P assume that the arg is a REG rtx