public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug debug/13111] New: g++ debuginfo incorrect for verify.cc
@ 2003-11-18 19:05 tromey at gcc dot gnu dot org
  2004-01-01 23:39 ` [Bug debug/13111] " pinskia at gcc dot gnu dot org
  2005-09-24  5:25 ` pinskia at gcc dot gnu dot org
  0 siblings, 2 replies; 3+ messages in thread
From: tromey at gcc dot gnu dot org @ 2003-11-18 19:05 UTC (permalink / raw)
  To: gcc-bugs

I found this problem while debugging Bug 13107.
It is fairly simple to reproduce.
The problem seems to be that g++ generates incorrect debug info;
in any case, gdb winds up with incorrect line numbers.
This didn't happen the last time I debugged the verifier, some months
ago.

First, build gcc including java.
I rebuilt libgcj with CXXFLAGS=-g (and also tried -g3).

Grab the test file from Bug 13107 and compile it:
gcj -C GIJ.java

Now run gdb on gij.  "b main"; "run GIJ"
When it stops, "b '_Jv_BytecodeVerifier::verify_instructions_0()'"
"cont"

I get:

Breakpoint 3, _Jv_BytecodeVerifier::verify_instructions_0() (this=0xbfffecf0)
    at ../../../gcc/libjava/verify.cc:995

But, whoops, line 995 is in operator new.
verify_instructions_0 doesn't start until line 2287.

There are plenty of other similar problems with the debuginfo in this
file; this is just the easiest one to find.  This makes debugging
the verifier very difficult.

-- 
           Summary: g++ debuginfo incorrect for verify.cc
           Product: gcc
           Version: 3.4
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: debug
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: tromey at gcc dot gnu dot org
                CC: gcc-bugs at gcc dot gnu dot org
  GCC host triplet: i686-pc-linux-gnu


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13111


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug debug/13111] g++ debuginfo incorrect for verify.cc
  2003-11-18 19:05 [Bug debug/13111] New: g++ debuginfo incorrect for verify.cc tromey at gcc dot gnu dot org
@ 2004-01-01 23:39 ` pinskia at gcc dot gnu dot org
  2005-09-24  5:25 ` pinskia at gcc dot gnu dot org
  1 sibling, 0 replies; 3+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-01-01 23:39 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2004-01-01 23:39 -------
Confirmed but I think there is a dup of this bug, the problem is that operator new is inlined 
so the first instruction is part of operator new so the line number is the first  instruction that 
way.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|                            |1
           Keywords|                            |wrong-code
   Last reconfirmed|0000-00-00 00:00:00         |2004-01-01 23:39:22
               date|                            |


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13111


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug debug/13111] g++ debuginfo incorrect for verify.cc
  2003-11-18 19:05 [Bug debug/13111] New: g++ debuginfo incorrect for verify.cc tromey at gcc dot gnu dot org
  2004-01-01 23:39 ` [Bug debug/13111] " pinskia at gcc dot gnu dot org
@ 2005-09-24  5:25 ` pinskia at gcc dot gnu dot org
  1 sibling, 0 replies; 3+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-09-24  5:25 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2005-09-24 05:25 -------
Actually I think this is gdb issue as it does not read the extra info provided by GCC now for inlined 
functions.

-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13111


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2005-09-24  5:25 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-11-18 19:05 [Bug debug/13111] New: g++ debuginfo incorrect for verify.cc tromey at gcc dot gnu dot org
2004-01-01 23:39 ` [Bug debug/13111] " pinskia at gcc dot gnu dot org
2005-09-24  5:25 ` pinskia at gcc dot gnu dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).