unwind-ia64.c (uw_frame_state_for): Don't assume a leaf function without unwind info...
authorJakub Jelinek <jakub@redhat.com>
Thu, 10 Jun 2004 08:23:00 +0000 (10:23 +0200)
committerJakub Jelinek <jakub@gcc.gnu.org>
Thu, 10 Jun 2004 08:23:00 +0000 (10:23 +0200)
* config/ia64/unwind-ia64.c (uw_frame_state_for): Don't assume a
leaf function without unwind info at RP 0.

From-SVN: r82906

gcc/ChangeLog
gcc/config/ia64/unwind-ia64.c

index fa7c16d3489066c648ad3de7ae1175b98ad8cfab..ed3165aa8503c4f3aa3f61867ba3fe197363c7c0 100644 (file)
@@ -1,3 +1,8 @@
+2004-06-10  Jakub Jelinek  <jakub@redhat.com>
+
+       * config/ia64/unwind-ia64.c (uw_frame_state_for): Don't assume a
+       leaf function without unwind info at RP 0.
+
 2004-06-10  Jakub Jelinek  <jakub@redhat.com>
 
        PR c++/14791
index b4fe9ac1c4c2852012053bf9f37f7e47d211b783..1c88b72906414cae30afcc3eb7836164c99e6d57 100644 (file)
@@ -1783,8 +1783,10 @@ uw_frame_state_for (struct _Unwind_Context *context, _Unwind_FrameState *fs)
         an unwind table entry.
 
         This can only happen in the frame after unwinding through a signal
-        handler.  Avoid infinite looping by requiring that B0 != RP.  */
-      if (context->br_loc[0] && *context->br_loc[0] != context->rp)
+        handler.  Avoid infinite looping by requiring that B0 != RP.
+        RP == 0 terminates the chain.  */
+      if (context->br_loc[0] && *context->br_loc[0] != context->rp
+         && context->rp != 0)
        {
          fs->curr.reg[UNW_REG_RP].where = UNW_WHERE_BR;
          fs->curr.reg[UNW_REG_RP].when = -1;