]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
stmt.c (expand_fixup): Set fixup->before_jump to a NOTE_INSN_DELETED instead of a...
authorJason Merrill <jason@yorick.cygnus.com>
Sun, 25 Oct 1998 23:54:41 +0000 (23:54 +0000)
committerJeff Law <law@gcc.gnu.org>
Sun, 25 Oct 1998 23:54:41 +0000 (16:54 -0700)
* stmt.c (expand_fixup): Set fixup->before_jump to a
NOTE_INSN_DELETED instead of a NOTE_INSN_BLOCK_BEG.

From-SVN: r23328

gcc/ChangeLog
gcc/stmt.c

index 402c92532fb39c458fb768d6edf12c78523f4935..27564674d11eb52943ef6b9b1ed8a6d40b4293a3 100644 (file)
@@ -1,3 +1,8 @@
+Sun Oct 25 23:36:52 1998  Jason Merrill  <jason@yorick.cygnus.com>
+
+       * stmt.c (expand_fixup): Set fixup->before_jump to a
+       NOTE_INSN_DELETED instead of a NOTE_INSN_BLOCK_BEG.
+
 Sun Oct 25 18:35:06 1998  David Edelsohn  <edelsohn@mhpcc.edu>
 
        * ginclude/va-ppc.h (va_arg): longlong types in overflow area are
index 9ebe6705e0f629f1958458dcceac461199b9e210..8d11a75774461ea7783fa023860b2dda87520645 100644 (file)
@@ -885,19 +885,25 @@ expand_fixup (tree_label, rtl_label, last_insn)
         code which we might later insert at this point in the insn
         stream.  Also, the BLOCK node will be the parent (i.e. the
         `SUPERBLOCK') of any other BLOCK nodes which we might create
-        later on when we are expanding the fixup code.  */
+        later on when we are expanding the fixup code.
+
+        Note that optimization passes (including expand_end_loop)
+        might move the *_BLOCK notes away, so we use a NOTE_INSN_DELETED
+        as a placeholder.  */
 
       {
         register rtx original_before_jump
           = last_insn ? last_insn : get_last_insn ();
+       rtx start;
 
         start_sequence ();
         pushlevel (0);
-        fixup->before_jump = emit_note (NULL_PTR, NOTE_INSN_BLOCK_BEG);
+        start = emit_note (NULL_PTR, NOTE_INSN_BLOCK_BEG);
+       fixup->before_jump = emit_note (NULL_PTR, NOTE_INSN_DELETED);
         last_block_end_note = emit_note (NULL_PTR, NOTE_INSN_BLOCK_END);
         fixup->context = poplevel (1, 0, 0);  /* Create the BLOCK node now! */
         end_sequence ();
-        emit_insns_after (fixup->before_jump, original_before_jump);
+        emit_insns_after (start, original_before_jump);
       }
 
       fixup->block_start_count = block_start_count;