delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp-workers/2001/07/28/04:54:22

Date: Sat, 28 Jul 2001 04:54:22 -0400
Message-Id: <200107280854.EAA31809@delorie.com>
X-Authentication-Warning: delorie.com: eliz set sender to eliz AT delorie DOT com using -f
From: Eli Zaretskii <eliz AT delorie DOT com>
To: djgpp-workers AT delorie DOT com
Subject: Bug in COFF debug info
Reply-To: djgpp-workers AT delorie DOT com

Consider the following program:

#include <stdio.h>

double one = 1.0;

int main (void)
{
  double d;

  d = 2.0*one;
  printf ("%f\n", d);
  return 0;
}

Now observe:

  gcc -g -O -o ftest.exe ftest.c
  gdb ftest.exe
  (gdb) break main
  Breakpoint 1 at 0x15a6: file fpreg.c, line 984

Huh?  What line 984?  This file has only 12 lines.

This doesn't happen with -gstabs+.

On this machine, I have GCC 3.0 and Binutils 2.11.  I vaguely recall
something about problems with COFF debug info either in GCC or in
Binutils, but I don't recall the details, and cannot test other
combinations of the compiler and Binutils on this machine.

Is this a known problem with one of these two packages, or should I
investigate more?

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019