aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBernd Schmidt <bernds@redhat.co.uk>2000-11-10 11:43:43 +0000
committerBernd Schmidt <bernds@gcc.gnu.org>2000-11-10 11:43:43 +0000
commit0c478921bdadb374b8c4b062c4812c659564b9cb (patch)
treec859b1859843b9c3c1592f38690e2b4e0ef02343
parent6fb85418122c9a3bde93c7db8e185c2d0f53413a (diff)
downloadgcc-0c478921bdadb374b8c4b062c4812c659564b9cb.zip
gcc-0c478921bdadb374b8c4b062c4812c659564b9cb.tar.gz
gcc-0c478921bdadb374b8c4b062c4812c659564b9cb.tar.bz2
Fix ia64 float extend splitter crash.
From-SVN: r37365
-rw-r--r--gcc/ChangeLog5
-rw-r--r--gcc/config/ia64/ia64.md27
-rw-r--r--gcc/toplev.c2
3 files changed, 30 insertions, 4 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 4ff995e..9625f27 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -3,6 +3,11 @@
* regrename.c (build_def_use): Mark contents of REG_INC notes as
needing replacement.
+ * config/ia64/ia64.md (extendsfdf2, extendsftf2, extenddftf2): Emit
+ a no-op move if regs are equal.
+ * toplev.c (rest_of_compilation): Do the noop moves elimination pass
+ when calling jump after post-reload splitting.
+
2000-11-09 Jan van Male <jan.vanmale@fenk.wau.nl>
* c-tree.texi: Fix typos.
diff --git a/gcc/config/ia64/ia64.md b/gcc/config/ia64/ia64.md
index 5adc646..77418f2 100644
--- a/gcc/config/ia64/ia64.md
+++ b/gcc/config/ia64/ia64.md
@@ -1073,7 +1073,14 @@
getf.d %0 = %1"
"reload_completed"
[(set (match_dup 0) (float_extend:DF (match_dup 1)))]
- "if (true_regnum (operands[0]) == true_regnum (operands[1])) DONE;"
+ "
+{
+ if (true_regnum (operands[0]) == true_regnum (operands[1]))
+ {
+ emit_insn (gen_movdi (pic_offset_table_rtx, pic_offset_table_rtx));
+ DONE;
+ }
+}"
[(set_attr "type" "F,F,M,M,M,M")])
(define_insn_and_split "extendsftf2"
@@ -1089,7 +1096,14 @@
stfe %0 = %1%P0"
"reload_completed"
[(set (match_dup 0) (float_extend:TF (match_dup 1)))]
- "if (true_regnum (operands[0]) == true_regnum (operands[1])) DONE;"
+ "
+{
+ if (true_regnum (operands[0]) == true_regnum (operands[1]))
+ {
+ emit_insn (gen_movdi (pic_offset_table_rtx, pic_offset_table_rtx));
+ DONE;
+ }
+}"
[(set_attr "type" "F,F,M,M,M")])
(define_insn_and_split "extenddftf2"
@@ -1105,7 +1119,14 @@
stfe %0 = %1%P0"
"reload_completed"
[(set (match_dup 0) (float_extend:TF (match_dup 1)))]
- "if (true_regnum (operands[0]) == true_regnum (operands[1])) DONE;"
+ "
+{
+ if (true_regnum (operands[0]) == true_regnum (operands[1]))
+ {
+ emit_insn (gen_movdi (pic_offset_table_rtx, pic_offset_table_rtx));
+ DONE;
+ }
+}"
[(set_attr "type" "F,F,M,M,M")])
(define_insn "truncdfsf2"
diff --git a/gcc/toplev.c b/gcc/toplev.c
index aa8c4ba..1f46f35 100644
--- a/gcc/toplev.c
+++ b/gcc/toplev.c
@@ -3484,7 +3484,7 @@ rest_of_compilation (decl)
open_dump_file (DFI_flow2, decl);
jump_optimize (insns, !JUMP_CROSS_JUMP,
- !JUMP_NOOP_MOVES, !JUMP_AFTER_REGSCAN);
+ JUMP_NOOP_MOVES, !JUMP_AFTER_REGSCAN);
find_basic_blocks (insns, max_reg_num (), rtl_dump_file);
/* On some machines, the prologue and epilogue code, or parts thereof,