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]
Other format: [Raw text]

Re: C ASSEMBLER_NAME patch


I have a similar problem with function names transforming from
"foo" to "foo.0" in the debug info.  It's causing a bit of
heartburn for gdb.

Here is the source code:

  static void f1 (int i);
  static void f1 (int i)
  {
    return;
  }

Here is the output from gcc HEAD 20030716:

	  .stabs  "f1:f(0,21)=(0,21)",36,0,3,f1                                           .stabs  "i:p(0,1)",160,0,2,8
	  .type   f1, @function                                                   f1:
	  .stabn 68,0,3,.LM1-f1

And here is the output from gcc HEAD 20030722:

	  .stabs  "f1.0:f(0,21)=(0,21)",36,0,3,f1.0
	  .stabs  "i:p(0,1)",160,0,2,8                                                    .type   f1.0, @function
  f1.0:                                                                                   .stabn 68,0,3,.LM1-f1.0

The function name change from "f1" to "f1.0", even though "f1"
is declared and defined at file scope.  This happens with -gstabs+.
It does not happen with -gdwarf-2 (or if it does, gdb is handling
it okay).

Platform: native i686-pc-linux-gnu, red hat linux 8, binutils 2.14,
-gstabs+ debugging format.

I'll wait a couple of days to see if this blows over before filing
a bug report.

Michael C


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