summaryrefslogtreecommitdiff
path: root/gcc/dwarf2out.c
diff options
context:
space:
mode:
authorlaw <law@138bc75d-0d04-0410-961f-82ee72b054a4>1999-11-10 22:57:48 +0000
committerlaw <law@138bc75d-0d04-0410-961f-82ee72b054a4>1999-11-10 22:57:48 +0000
commitf24a85f3616d4b2999ecdb08b73964d8dc891611 (patch)
tree0ccb5ba3f60d51f76c013e7a59bf5f0366aae135 /gcc/dwarf2out.c
parentea935d05004c7419f620c6ac7eed98ddb7def849 (diff)
downloadgcc-f24a85f3616d4b2999ecdb08b73964d8dc891611.tar.gz
* dwarf2out.c (add_AT_location_description): Allow
(mem (plus (pseudo) (...)) too. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@30480 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/dwarf2out.c')
-rw-r--r--gcc/dwarf2out.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/gcc/dwarf2out.c b/gcc/dwarf2out.c
index 232ec81fca8..c4ee8ca1058 100644
--- a/gcc/dwarf2out.c
+++ b/gcc/dwarf2out.c
@@ -6732,6 +6732,13 @@ add_AT_location_description (die, attr_kind, rtl)
if (is_pseudo_reg (rtl)
|| (GET_CODE (rtl) == MEM
&& is_pseudo_reg (XEXP (rtl, 0)))
+ /* This can happen for a PARM_DECL with a DECL_INCOMING_RTL which
+ references the internal argument pointer (a pseudo) in a function
+ where all references to the internal argument pointer were
+ eliminated via the optimizers. */
+ || (GET_CODE (rtl) == MEM
+ && GET_CODE (XEXP (rtl, 0)) == PLUS
+ && is_pseudo_reg (XEXP (XEXP (rtl, 0), 0)))
|| (GET_CODE (rtl) == CONCAT
&& is_pseudo_reg (XEXP (rtl, 0))
&& is_pseudo_reg (XEXP (rtl, 1))))