aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorKazu Hirata <kazu@cs.umass.edu>2003-07-02 20:48:04 +0000
committerKazu Hirata <kazu@gcc.gnu.org>2003-07-02 20:48:04 +0000
commitfad37371f9c9b29b05761a8014ff3b1d79dd637f (patch)
treee7fb60ac901a9b7f428eb6c9b8c3a0344b18f7cd /gcc
parent836d77a9f4d32c9806e6b2e4feae639eb45aa9a9 (diff)
downloadgcc-fad37371f9c9b29b05761a8014ff3b1d79dd637f.zip
gcc-fad37371f9c9b29b05761a8014ff3b1d79dd637f.tar.gz
gcc-fad37371f9c9b29b05761a8014ff3b1d79dd637f.tar.bz2
h8300.c (compute_mov_length): Fix the length of loading CONST0_RTX (SFmode).
* config/h8300/h8300.c (compute_mov_length): Fix the length of loading CONST0_RTX (SFmode). * config/h8300/h8300.h (CONST_DOUBLE_OK_FOR_LETTER_P): Change 'G' to CONST0_RTX (SFmode). * config/h8300/h8300.md (movsf_h8300): Change the first constraint to 'G'. (movsf_h8300h): Likewise. From-SVN: r68854
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog10
-rw-r--r--gcc/config/h8300/h8300.c2
-rw-r--r--gcc/config/h8300/h8300.h2
-rw-r--r--gcc/config/h8300/h8300.md4
4 files changed, 14 insertions, 4 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index d18086a..02d6731 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,13 @@
+2003-07-02 Kazu Hirata <kazu@cs.umass.edu>
+
+ * config/h8300/h8300.c (compute_mov_length): Fix the length of
+ loading CONST0_RTX (SFmode).
+ * config/h8300/h8300.h (CONST_DOUBLE_OK_FOR_LETTER_P): Change
+ 'G' to CONST0_RTX (SFmode).
+ * config/h8300/h8300.md (movsf_h8300): Change the first
+ constraint to 'G'.
+ (movsf_h8300h): Likewise.
+
2003-07-02 Neil Booth <neil@daikokuya.co.uk>
* c-common.h (c_common_init_options): New prototype.
diff --git a/gcc/config/h8300/h8300.c b/gcc/config/h8300/h8300.c
index f1d3577..da0cd3f 100644
--- a/gcc/config/h8300/h8300.c
+++ b/gcc/config/h8300/h8300.c
@@ -2010,7 +2010,7 @@ compute_mov_length (rtx *operands)
if (REG_P (src))
return 2;
- if (src == const0_rtx)
+ if (CONST_DOUBLE_OK_FOR_LETTER_P (src, 'G'))
return 2;
return 6;
}
diff --git a/gcc/config/h8300/h8300.h b/gcc/config/h8300/h8300.h
index c6918c2..ba8dcff 100644
--- a/gcc/config/h8300/h8300.h
+++ b/gcc/config/h8300/h8300.h
@@ -484,7 +484,7 @@ enum reg_class {
`G' is a floating-point zero. */
#define CONST_DOUBLE_OK_FOR_LETTER_P(VALUE, C) \
- ((C) == 'G' ? (VALUE) == CONST0_RTX (DFmode) \
+ ((C) == 'G' ? (VALUE) == CONST0_RTX (SFmode) \
: 0)
/* Given an rtx X being reloaded into a reg required to be
diff --git a/gcc/config/h8300/h8300.md b/gcc/config/h8300/h8300.md
index ad1d348..9a579ec 100644
--- a/gcc/config/h8300/h8300.md
+++ b/gcc/config/h8300/h8300.md
@@ -420,7 +420,7 @@
(define_insn "*movsf_h8300"
[(set (match_operand:SF 0 "general_operand_dst" "=r,r,r,o,<,r")
- (match_operand:SF 1 "general_operand_src" "I,r,io,r,r,>"))]
+ (match_operand:SF 1 "general_operand_src" "G,r,io,r,r,>"))]
"TARGET_H8300
&& (register_operand (operands[0], SFmode)
|| register_operand (operands[1], SFmode))"
@@ -553,7 +553,7 @@
(define_insn "*movsf_h8300h"
[(set (match_operand:SF 0 "general_operand_dst" "=r,r,r,m,<,r")
- (match_operand:SF 1 "general_operand_src" "I,r,im,r,r,>"))]
+ (match_operand:SF 1 "general_operand_src" "G,r,im,r,r,>"))]
"(TARGET_H8300H || TARGET_H8300S)
&& (register_operand (operands[0], SFmode)
|| register_operand (operands[1], SFmode))"