aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog6
-rw-r--r--gcc/combine.c21
2 files changed, 21 insertions, 6 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index a4bb170..5240478 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,9 @@
+2000-04-24 Nick Clifton <nickc@redhat.com>
+
+ * combine.c (combine_instructions): Do not try to combine a
+ sequence of insns when the second insn has been replaced by a
+ note.
+
Mon Apr 24 17:34:18 2000 Mumit Khan <khan@xraylith.wisc.edu>
* gcc.c (load_specs): New static function.
diff --git a/gcc/combine.c b/gcc/combine.c
index 9396959..366ada7 100644
--- a/gcc/combine.c
+++ b/gcc/combine.c
@@ -646,12 +646,21 @@ combine_instructions (f, nregs)
/* Try each sequence of three linked insns ending with this one. */
for (links = LOG_LINKS (insn); links; links = XEXP (links, 1))
- for (nextlinks = LOG_LINKS (XEXP (links, 0)); nextlinks;
- nextlinks = XEXP (nextlinks, 1))
- if ((next = try_combine (insn, XEXP (links, 0),
- XEXP (nextlinks, 0),
- &new_direct_jump_p)) != 0)
- goto retry;
+ {
+ rtx link = XEXP (links, 0);
+
+ /* If the linked insn has been replaced by a note, then there
+ is no point in persuing this chain any further. */
+ if (GET_CODE (link) == NOTE)
+ break;
+
+ for (nextlinks = LOG_LINKS (link);
+ nextlinks;
+ nextlinks = XEXP (nextlinks, 1))
+ if ((next = try_combine (insn, XEXP (links, 0),
+ XEXP (nextlinks, 0))) != 0)
+ goto retry;
+ }
#ifdef HAVE_cc0
/* Try to combine a jump insn that uses CC0