aboutsummaryrefslogtreecommitdiff
path: root/gcc/reload1.c
diff options
context:
space:
mode:
authorJeff Law <law@gcc.gnu.org>1998-10-31 12:44:19 -0700
committerJeff Law <law@gcc.gnu.org>1998-10-31 12:44:19 -0700
commitfaa6e5c4103e211e52ea5fd0d7f4cf25ae9624b5 (patch)
treeb45c80d2de56d04f3dc050ec628b6fbc7939cc6d /gcc/reload1.c
parent549f2254b6880f1315acccb0933672c1c905c50d (diff)
downloadgcc-faa6e5c4103e211e52ea5fd0d7f4cf25ae9624b5.zip
gcc-faa6e5c4103e211e52ea5fd0d7f4cf25ae9624b5.tar.gz
gcc-faa6e5c4103e211e52ea5fd0d7f4cf25ae9624b5.tar.bz2
toplev.c (rest_of_compilation): No longer set reload_completed.
� * toplev.c (rest_of_compilation): No longer set reload_completed. * reload1.c (reload): Set it here. Perform instruction splitting after reload has completed if we will be running the scheduler again. From-SVN: r23478
Diffstat (limited to 'gcc/reload1.c')
-rw-r--r--gcc/reload1.c22
1 files changed, 22 insertions, 0 deletions
diff --git a/gcc/reload1.c b/gcc/reload1.c
index 831436c..9c7a22e 100644
--- a/gcc/reload1.c
+++ b/gcc/reload1.c
@@ -1049,6 +1049,10 @@ reload (first, global, dumpfile)
}
}
+ /* We've finished reloading. This reload_completed must be set before we
+ perform instruction splitting below. */
+ reload_completed = 1;
+
/* Make a pass over all the insns and delete all USEs which we inserted
only to tag a REG_EQUAL note on them. Remove all REG_DEAD and REG_UNUSED
notes. Delete all CLOBBER insns and simplify (subreg (reg)) operands. */
@@ -1080,6 +1084,24 @@ reload (first, global, dumpfile)
/* And simplify (subreg (reg)) if it appears as an operand. */
cleanup_subreg_operands (insn);
+
+ /* If optimizing and we are performing instruction scheduling after
+ reload, then go ahead and split insns now since we are about to
+ recompute flow information anyway. */
+ if (optimize && flag_schedule_insns_after_reload)
+ {
+ rtx last, first;
+
+ last = try_split (PATTERN (insn), insn, 1);
+
+ if (last != insn)
+ {
+ PUT_CODE (insn, NOTE);
+ NOTE_SOURCE_FILE (insn) = 0;
+ NOTE_LINE_NUMBER (insn) = NOTE_INSN_DELETED;
+ }
+ }
+
}
/* If we are doing stack checking, give a warning if this function's