This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[GOOGLE] Emit linkage_name when built with -gmlt and for abstract decls
- From: Dehao Chen <dehao at google dot com>
- To: GCC Patches <gcc-patches at gcc dot gnu dot org>, Cary Coutant <ccoutant at google dot com>
- Date: Fri, 16 Aug 2013 16:09:10 -0700
- Subject: [GOOGLE] Emit linkage_name when built with -gmlt and for abstract decls
This patch emits linkage_name at -gmlt. It also make sure abstract
decls' linkage_names are emitted so that inlined functions can also
find linkage name.
Bootstrapped and passed regression test.
OK for google branches?
Thanks,
Dehao
Index: gcc/dwarf2out.c
===================================================================
--- gcc/dwarf2out.c (revision 201632)
+++ gcc/dwarf2out.c (working copy)
@@ -16537,10 +16537,9 @@ add_src_coords_attributes (dw_die_ref die, tree de
static void
add_linkage_name (dw_die_ref die, tree decl)
{
- if (debug_info_level > DINFO_LEVEL_TERSE
+ if (debug_info_level > DINFO_LEVEL_NONE
&& (TREE_CODE (decl) == FUNCTION_DECL || TREE_CODE (decl) == VAR_DECL)
&& TREE_PUBLIC (decl)
- && !DECL_ABSTRACT (decl)
&& !(TREE_CODE (decl) == VAR_DECL && DECL_REGISTER (decl))
&& die->die_tag != DW_TAG_member)
{