re PR target/17406 (ICE dwarf2out_frame_debug_expr, at dwarf2out.c:1692)
authorRichard Henderson <rth@redhat.com>
Tue, 28 Dec 2004 05:26:23 +0000 (21:26 -0800)
committerRichard Henderson <rth@gcc.gnu.org>
Tue, 28 Dec 2004 05:26:23 +0000 (21:26 -0800)
        PR target/17406
        * config/i386/i386.c (ix86_expand_prologue): Add REG_FRAME_RELATED_EXPR
        note for allocate_stack_worker insn.

From-SVN: r92662

gcc/ChangeLog
gcc/config/i386/i386.c

index 6c6860be8dbb75728c345b05ab102e93a39138ab..9f1531ed77c18c0f1071f34c912346d72b08f7ca 100644 (file)
@@ -1,3 +1,9 @@
+2004-12-27  Richard Henderson  <rth@redhat.com>
+
+       PR target/17406
+       * config/i386/i386.c (ix86_expand_prologue): Add REG_FRAME_RELATED_EXPR
+       note for allocate_stack_worker insn.
+
 2004-12-27  Jason Merrill  <jason@redhat.com>
 
        * doc/tm.texi (TARGET_RELAXED_ORDERING): Document.
index 054da85e404137da548c76ea9a2f26d2ab9b6b94..6e65969cdb66ec81af997207b335b09e93c2c49d 100644 (file)
@@ -4331,6 +4331,7 @@ ix86_expand_prologue (void)
       /* Only valid for Win32.  */
       rtx eax = gen_rtx_REG (SImode, 0);
       bool eax_live = ix86_eax_live_at_start_p ();
+      rtx t;
 
       if (TARGET_64BIT)
         abort ();
@@ -4341,15 +4342,17 @@ ix86_expand_prologue (void)
          allocate -= 4;
        }
 
-      insn = emit_move_insn (eax, GEN_INT (allocate));
-      RTX_FRAME_RELATED_P (insn) = 1;
+      emit_move_insn (eax, GEN_INT (allocate));
 
       insn = emit_insn (gen_allocate_stack_worker (eax));
       RTX_FRAME_RELATED_P (insn) = 1;
+      t = gen_rtx_PLUS (Pmode, stack_pointer_rtx, GEN_INT (-allocate));
+      t = gen_rtx_SET (VOIDmode, stack_pointer_rtx, t);
+      REG_NOTES (insn) = gen_rtx_EXPR_LIST (REG_FRAME_RELATED_EXPR,
+                                           t, REG_NOTES (insn));
 
       if (eax_live)
        {
-         rtx t;
          if (frame_pointer_needed)
            t = plus_constant (hard_frame_pointer_rtx,
                               allocate