This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Patch to dwarf2out.c


It doesn't make sense for static locals to have their linkage name listed, and
it breaks gdb.

2000-03-13  Jason Merrill  <jason@casey.cygnus.com>

	* dwarf2out.c (add_name_and_src_coords_attributes): Only add
	DW_AT_MIPS_linkage_name for TREE_PUBLIC decls.
	(ASM_OUTPUT_DWARF_ADDR_CONST): Don't output trailing newline.

Index: dwarf2out.c
===================================================================
RCS file: /cvs/gcc/egcs/gcc/dwarf2out.c,v
retrieving revision 1.160
diff -c -p -r1.160 dwarf2out.c
*** dwarf2out.c	2000/03/09 19:01:47	1.160
--- dwarf2out.c	2000/03/13 15:07:50
*************** dwarf2out.c	P
*** 365,371 ****
    do {									\
      fprintf ((FILE), "\t%s\t", UNALIGNED_WORD_ASM_OP);			\
      output_addr_const ((FILE), (RTX));					\
-     fputc ('\n', (FILE));						\
    } while (0)
  #endif
  
--- 365,370 ----
*************** add_name_and_src_coords_attributes (die,
*** 7464,7469 ****
--- 7463,7469 ----
  	add_src_coords_attributes (die, decl);
  
        if ((TREE_CODE (decl) == FUNCTION_DECL || TREE_CODE (decl) == VAR_DECL)
+ 	  && TREE_PUBLIC (decl)
  	  && DECL_ASSEMBLER_NAME (decl) != DECL_NAME (decl))
  	add_AT_string (die, DW_AT_MIPS_linkage_name,
  		       IDENTIFIER_POINTER (DECL_ASSEMBLER_NAME (decl)));

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]