public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug java/13743] New: Debug Info for Java breaks inferior calls
@ 2004-01-19 17:16 aph at gcc dot gnu dot org
  2004-01-19 17:22 ` [Bug java/13743] " aph at gcc dot gnu dot org
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: aph at gcc dot gnu dot org @ 2004-01-19 17:16 UTC (permalink / raw)
  To: gcc-bugs

From: Jeff Johnston <jjohnstn at redhat.com>

  In doing some more testing with java inferior call, I found a key 
difference between the java and C++ debug info files that is causing gdb 
some grief.  We can't make inferior calls to non-static java members as 
we can't find the vtable.

  In C++, the vtable is being represented by a special member called 
_vptr.class.  In the DW_AT_structure_type for the class, it has a 
special DW_AT_containing_type tag which points to the class that 
contains this _vptr member.  In this case, Property has the _vptr entry 
so it points to itself.  Gdb is specifically looking for this _vptr 
entry and if it can't find it, gives up trying to resolve a virtual 
member function.

  In java, the DW_AT_containing_type tag is missing from the 
DW_AT_structure_type and there isn't a _vptr member entry.  I did find a 
vtable member in java.lang.Object but I don't know if that is the same.  
It might be possible just to point the containing_type to the 
java.lang.Object and then have gdb understand and use the vtable entry.  
Any thoughts?  We're kind of in unchartered ground here.

  I have included a better C++ example for you to look at with the debug 
info from readelf -wi.  The member function dothat() in the Property 
class is comparable from java to C++.

-- 
           Summary: Debug Info for Java breaks inferior calls
           Product: gcc
           Version: 3.4.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: java
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: aph at gcc dot gnu dot org
                CC: gcc-bugs at gcc dot gnu dot org


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


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

end of thread, other threads:[~2004-11-06 15:48 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-01-19 17:16 [Bug java/13743] New: Debug Info for Java breaks inferior calls aph at gcc dot gnu dot org
2004-01-19 17:22 ` [Bug java/13743] " aph at gcc dot gnu dot org
2004-01-23 11:13 ` aph at gcc dot gnu dot org
2004-02-27 14:57 ` aph at redhat dot com
2004-09-28 17:45 ` aph at gcc dot gnu dot org
2004-11-06 15:48 ` 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).