haifa-sched.c (reemit_notes): Tidy.
authorRichard Henderson <rth@cygnus.com>
Fri, 23 Jul 1999 01:26:40 +0000 (18:26 -0700)
committerRichard Henderson <rth@gcc.gnu.org>
Fri, 23 Jul 1999 01:26:40 +0000 (18:26 -0700)
        * haifa-sched.c (reemit_notes): Tidy.
        * sched.c (reemit_notes): Duplicate 1998-08-31 patch to
        haifa's routine.

From-SVN: r28223

gcc/ChangeLog
gcc/haifa-sched.c
gcc/sched.c

index 8f24efcf2a2dbeaa072a2f2e24ccee8582175c0c..776115ec109fcef223b6de39a6f523414f3a79ee 100644 (file)
@@ -1,3 +1,9 @@
+Thu Jul 22 18:23:56 1999  Richard Henderson  <rth@cygnus.com>
+
+       * haifa-sched.c (reemit_notes): Tidy.
+       * sched.c (reemit_notes): Duplicate 1998-08-31 patch to
+       haifa's routine.
+
 Thu Jul 22 18:21:04 1999  Richard Henderson  <rth@cygnus.com>
 
        * explow.c (trunc_int_for_mode): New function.
index 9325f61e19dfd2c5f6b4112f53458aab7555ac9c..60b340fa788b15ba82e33d042fffe65516ca2aa1 100644 (file)
@@ -6597,7 +6597,7 @@ reemit_notes (insn, last)
            }
          else
            {
-             last = emit_note_before (INTVAL (XEXP (note, 0)), last);
+             last = emit_note_before (note_type, last);
              remove_note (insn, note);
              note = XEXP (note, 1);
              NOTE_BLOCK_NUMBER (last) = INTVAL (XEXP (note, 0));
index e8cd070e45c8c9885fe9f949b6e95b9a9fc0df85..c0eb5dc9651412c2795bf403ed920981811919b5 100644 (file)
@@ -2578,16 +2578,25 @@ reemit_notes (insn, last)
       if (REG_NOTE_KIND (note) == REG_DEAD
          && GET_CODE (XEXP (note, 0)) == CONST_INT)
        {
-         if (INTVAL (XEXP (note, 0)) == NOTE_INSN_SETJMP)
+         int note_type = INTVAL (XEXP (note, 0));
+         if (note_type == NOTE_INSN_SETJMP)
            {
-             CONST_CALL_P (emit_note_after (INTVAL (XEXP (note, 0)), insn))
+             CONST_CALL_P (emit_note_after (note_type, insn))
                = CONST_CALL_P (note);
              remove_note (insn, note);
              note = XEXP (note, 1);
            }
+         else if (note_type == NOTE_INSN_RANGE_START
+                   || note_type == NOTE_INSN_RANGE_END)
+           {
+             last = emit_note_before (note_type, last);
+             remove_note (insn, note);
+             note = XEXP (note, 1);
+             NOTE_RANGE_INFO (last) = XEXP (note, 0);
+           }
          else
            {
-             last = emit_note_before (INTVAL (XEXP (note, 0)), last);
+             last = emit_note_before (note_type, last);
              remove_note (insn, note);
              note = XEXP (note, 1);
              NOTE_BLOCK_NUMBER (last) = INTVAL (XEXP (note, 0));