diff options
author | Nick Clifton <nickc@redhat.com> | 2000-04-25 00:40:36 +0000 |
---|---|---|
committer | Nick Clifton <nickc@gcc.gnu.org> | 2000-04-25 00:40:36 +0000 |
commit | aabb6c7408f8d51575e9cdaac5e9296d82d27b52 (patch) | |
tree | 37c99ee8398db84271209311cf3dba68f00bd517 | |
parent | a04678ca5666102eca111375a79c7e209663b2f1 (diff) | |
download | gcc-aabb6c7408f8d51575e9cdaac5e9296d82d27b52.zip gcc-aabb6c7408f8d51575e9cdaac5e9296d82d27b52.tar.gz gcc-aabb6c7408f8d51575e9cdaac5e9296d82d27b52.tar.bz2 |
Do not try to combine a sequence of insns when the second insn has been
replaced by a note.
From-SVN: r33398
-rw-r--r-- | gcc/ChangeLog | 6 | ||||
-rw-r--r-- | gcc/combine.c | 21 |
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 |