dwarf2out.c (add_AT_location_description): Allow (mem (plus (pseudo) (...)) too.
authorJeffrey A Law <law@cygnus.com>
Wed, 10 Nov 1999 22:57:48 +0000 (22:57 +0000)
committerJeff Law <law@gcc.gnu.org>
Wed, 10 Nov 1999 22:57:48 +0000 (15:57 -0700)
        * dwarf2out.c (add_AT_location_description): Allow
        (mem (plus (pseudo) (...)) too.

From-SVN: r30480

gcc/ChangeLog
gcc/dwarf2out.c

index a9a57ba8a49234d707372e49641aa1990f3607db..5e9480e7f270941518e03ea0835591738099f70c 100644 (file)
@@ -1,3 +1,8 @@
+Wed Nov 10 15:56:16 1999  Jeffrey A Law  (law@cygnus.com)
+
+        * dwarf2out.c (add_AT_location_description): Allow
+        (mem (plus (pseudo) (...)) too.
+
 Wed Nov 10 10:52:42 1999  Tom Tromey  <tromey@cygnus.com>
 
        * gcc.c (do_spec_1): Support text between `%u' and `%O'.
index 232ec81fca8aea49a743aeba79201250b5bef24f..c4ee8ca1058fcac6f03ec439fe1400f66f937b47 100644 (file)
@@ -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))))