diff options
| author | law <law@138bc75d-0d04-0410-961f-82ee72b054a4> | 1999-04-07 23:07:06 +0000 |
|---|---|---|
| committer | law <law@138bc75d-0d04-0410-961f-82ee72b054a4> | 1999-04-07 23:07:06 +0000 |
| commit | 8a040e41fa946150b79fb1757d8f77b38a824ce3 (patch) | |
| tree | 10383f39e505fddd7e5828eb29ff34a3d902f032 | |
| parent | 798df0ade2560d4459fac3d7fa9faa819774e724 (diff) | |
| download | ppe42-gcc-8a040e41fa946150b79fb1757d8f77b38a824ce3.tar.gz ppe42-gcc-8a040e41fa946150b79fb1757d8f77b38a824ce3.zip | |
* h8300.c (h8300_adjust_insn_length): Avoid trying to recognize
USE, CLOBBER or SEQUENCE insns.
* unroll.c (unroll_loop): For HAVE_cc0 machines, adjust copy_end_luid
to account for the uncopied insn that sets cc0 at the end of the loop.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@26283 138bc75d-0d04-0410-961f-82ee72b054a4
| -rw-r--r-- | gcc/ChangeLog | 6 | ||||
| -rw-r--r-- | gcc/config/h8300/h8300.c | 6 | ||||
| -rw-r--r-- | gcc/unroll.c | 8 |
3 files changed, 20 insertions, 0 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index d7c4dba6b4e..9497b2b08b3 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -13,6 +13,12 @@ Tue Apr 6 17:49:49 1999 Philip Blundell <pb@nexus.co.uk> Wed Apr 7 14:07:34 1999 Jeffrey A Law (law@cygnus.com) + * h8300.c (h8300_adjust_insn_length): Avoid trying to recognize + USE, CLOBBER or SEQUENCE insns. + + * unroll.c (unroll_loop): For HAVE_cc0 machines, adjust copy_end_luid + to account for the uncopied insn that sets cc0 at the end of the loop. + * unroll.c (copy_loop_body): Always ensure at least two insns are in the copied loop. diff --git a/gcc/config/h8300/h8300.c b/gcc/config/h8300/h8300.c index eb5d418aece..b181ae0f621 100644 --- a/gcc/config/h8300/h8300.c +++ b/gcc/config/h8300/h8300.c @@ -3033,6 +3033,12 @@ h8300_adjust_insn_length (insn, length) { rtx pat; + /* We must filter these ou before calling get_attr_adjust_length. */ + if (GET_CODE (PATTERN (insn)) == USE + || GET_CODE (PATTERN (insn)) == CLOBBER + || GET_CODE (PATTERN (insn)) == SEQUENCE) + return 0; + if (get_attr_adjust_length (insn) == ADJUST_LENGTH_NO) return 0; diff --git a/gcc/unroll.c b/gcc/unroll.c index 9c0109da86b..f1080aae701 100644 --- a/gcc/unroll.c +++ b/gcc/unroll.c @@ -790,6 +790,14 @@ unroll_loop (loop_end, insn_count, loop_start, end_insert_before, since it will also be used outside the loop. */ if (GET_CODE (copy_end) == JUMP_INSN) copy_end_luid--; + + /* If we have a target that uses cc0, then we also must not duplicate + the insn that sets cc0 before the jump insn. */ +#ifdef HAVE_cc0 + if (GET_CODE (copy_end) == JUMP_INSN) + copy_end_luid--; +#endif + /* If copy_start points to the NOTE that starts the loop, then we must use the next luid, because invariant pseudo-regs moved out of the loop have their lifetimes modified to start here, but they are not safe |

