This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[PATCH 01/28] mn10300: Better definition of INCOMING_RETURN_ADDR_RTX.
- From: Richard Henderson <rth at redhat dot com>
- To: gcc-patches at gcc dot gnu dot org
- Cc: nickc at redhat dot com, law at redhat dot com, Richard Henderson <rth at twiddle dot net>
- Date: Mon, 10 Jan 2011 12:31:30 -0800
- Subject: [PATCH 01/28] mn10300: Better definition of INCOMING_RETURN_ADDR_RTX.
- References: <1294691517-19580-1-git-send-email-rth@redhat.com>
From: Richard Henderson <rth@twiddle.net>
The new definition is more useful to the unwinder.
---
gcc/config/mn10300/mn10300.h | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
diff --git a/gcc/config/mn10300/mn10300.h b/gcc/config/mn10300/mn10300.h
index 67516b6..edc17f5 100644
--- a/gcc/config/mn10300/mn10300.h
+++ b/gcc/config/mn10300/mn10300.h
@@ -548,7 +548,10 @@ struct cum_arg
? gen_rtx_MEM (Pmode, arg_pointer_rtx) \
: (rtx) 0)
-#define INCOMING_RETURN_ADDR_RTX gen_rtx_REG (Pmode, MDR_REGNUM)
+/* The return address is saved both in the stack and in MDR. Using
+ the stack location is handiest for what unwinding needs. */
+#define INCOMING_RETURN_ADDR_RTX \
+ gen_rtx_MEM (VOIDmode, gen_rtx_REG (VOIDmode, STACK_POINTER_REGNUM))
/* Maximum number of registers that can appear in a valid memory address. */
--
1.7.3.4