re PR debug/54970 (Missing DW_OP_GNU_implicit_pointer in debuginfo)
authorJakub Jelinek <jakub@redhat.com>
Fri, 26 Oct 2012 19:19:25 +0000 (21:19 +0200)
committerJakub Jelinek <jakub@gcc.gnu.org>
Fri, 26 Oct 2012 19:19:25 +0000 (21:19 +0200)
commit9430b7bad813a444e6a7e35d6b5f92d2b99f40cf
tree007004e6f0b36e0efb8b580543d475b492da6928
parentc88538b7436c2e46f308b9b3410f04572078c2ae
re PR debug/54970 (Missing DW_OP_GNU_implicit_pointer in debuginfo)

PR debug/54970
* cfgexpand.c (expand_debug_expr): Expand &MEM_REF[&var, n]
as DEBUG_IMPLICIT_PTR + n if &var expands to DEBUG_IMPLICIT_PTR.
* tree-sra.c (create_access_replacement): Allow also MEM_REFs
with ADDR_EXPR first operand in DECL_DEBUG_EXPR expressions.
* var-tracking.c (track_expr_p): Handle MEM_REFs in DECL_DEBUG_EXPR
expressions.
* dwarf2out.c (add_var_loc_to_decl): Likewise.

PR debug/54971
* gcc.dg/guality/pr54970.c: New test.

From-SVN: r192860
gcc/ChangeLog
gcc/cfgexpand.c
gcc/dwarf2out.c
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.dg/guality/pr54970.c [new file with mode: 0644]
gcc/tree-sra.c
gcc/var-tracking.c