linux-mips
[Top] [All Lists]

Re: [PATCH 7/7] Allow unwind_stack() to return ra for leaf function

To: vagabon.xyz@gmail.com
Subject: Re: [PATCH 7/7] Allow unwind_stack() to return ra for leaf function
From: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Date: Wed, 02 Aug 2006 10:51:26 +0900 (JST)
Cc: ralf@linux-mips.org, linux-mips@linux-mips.org
In-reply-to: <cda58cb80608011238q5b0e0eacje28f921d6e1c7700@mail.gmail.com>
Original-recipient: rfc822;linux-mips@linux-mips.org
References: <1154424439969-git-send-email-vagabon.xyz@gmail.com> <20060802.004848.97296551.anemo@mba.ocn.ne.jp> <cda58cb80608011238q5b0e0eacje28f921d6e1c7700@mail.gmail.com>
Sender: linux-mips-bounce@linux-mips.org
On Tue, 1 Aug 2006 21:38:18 +0200, "Franck Bui-Huu" <vagabon.xyz@gmail.com> 
wrote:
> Considering (wrongly) a nested function as a leaf one is not a big
> issue. "ra" reg should _always_ store a valid address (nested or not).
> The only (small) impact would be to skip an entry when showing the
> backtrace.

The unwind_stack() uses regs->regs[31] for a leaf, and regs->regs[31]
always holds RA value of _top_ of the stack, not at that level.

---
Atsushi Nemoto

<Prev in Thread] Current Thread [Next in Thread>