public inbox for libabigail@sourceware.org
 help / color / mirror / Atom feed
* [Bug default/19204] New: assert in ../../src/abg-dwarf-reader.cc:5870
@ 2015-01-01  0:00 woodard at redhat dot com
  2016-01-01  0:00 ` [Bug default/19204] " woodard at redhat dot com
                   ` (7 more replies)
  0 siblings, 8 replies; 9+ messages in thread
From: woodard at redhat dot com @ 2015-01-01  0:00 UTC (permalink / raw)
  To: libabigail

https://sourceware.org/bugzilla/show_bug.cgi?id=19204

            Bug ID: 19204
           Summary: assert in ../../src/abg-dwarf-reader.cc:5870
           Product: libabigail
           Version: unspecified
            Status: NEW
          Severity: normal
          Priority: P2
         Component: default
          Assignee: dodji at redhat dot com
          Reporter: woodard at redhat dot com
                CC: libabigail at sourceware dot org
  Target Milestone: ---

Created attachment 8767
  --> https://sourceware.org/bugzilla/attachment.cgi?id=8767&action=edit
ELF object that reproduces the problem

hype356@ben:~/bin/abidw --abidiff
/collab/usr/global/tools/gperftools/2.4/bgqos_0/xlc@12.1/lib/libtcmalloc.so.4.2.6
abidw: ../../src/abg-dwarf-reader.cc:5870: void
abigail::dwarf_reader::get_parent_die(abigail::dwarf_reader::read_context&,
Dwarf_Die*, bool, Dwarf_Die&, size_t): Assertion `i !=
ctxt.die_parent_map().end()' failed.
Aborted (core dumped)

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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

* [Bug default/19204] assert in ../../src/abg-dwarf-reader.cc:5870
  2015-01-01  0:00 [Bug default/19204] New: assert in ../../src/abg-dwarf-reader.cc:5870 woodard at redhat dot com
                   ` (4 preceding siblings ...)
  2016-01-01  0:00 ` dodji at redhat dot com
@ 2016-01-01  0:00 ` woodard at redhat dot com
  2016-01-01  0:00 ` [Bug default/19204] libabigail aborts on DWARF referencing non-existing DIE dodji at redhat dot com
  2016-01-01  0:00 ` [Bug default/19204] assert in ../../src/abg-dwarf-reader.cc:5870 woodard at redhat dot com
  7 siblings, 0 replies; 9+ messages in thread
From: woodard at redhat dot com @ 2016-01-01  0:00 UTC (permalink / raw)
  To: libabigail

https://sourceware.org/bugzilla/show_bug.cgi?id=19204

--- Comment #1 from Ben Woodard <woodard at redhat dot com> ---
Reconfirmed with 1.0 RC1

hype356@ben:~/bin/abidw --abidiff
/collab/usr/global/tools/gperftools/2.4/bgqos_0/xlc@12.1/lib/libtcmalloc.so.4.2.6
abidw: ../../src/abg-dwarf-reader.cc:6072: void
abigail::dwarf_reader::get_parent_die(abigail::dwarf_reader::read_context&,
Dwarf_Die*, bool, Dwarf_Die&, size_t): Assertion `i !=
ctxt.die_parent_map().end()' failed.
Aborted (core dumped)

but the line number moved to 6072

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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

* [Bug default/19204] assert in ../../src/abg-dwarf-reader.cc:5870
  2015-01-01  0:00 [Bug default/19204] New: assert in ../../src/abg-dwarf-reader.cc:5870 woodard at redhat dot com
  2016-01-01  0:00 ` [Bug default/19204] " woodard at redhat dot com
  2016-01-01  0:00 ` [Bug default/19204] libabigail aborts on DWARF referencing non-existing DIE dodji at redhat dot com
@ 2016-01-01  0:00 ` dodji at redhat dot com
  2016-01-01  0:00 ` [Bug default/19204] libabigail aborts on DWARF referencing non-existing DIE dodji at redhat dot com
                   ` (4 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: dodji at redhat dot com @ 2016-01-01  0:00 UTC (permalink / raw)
  To: libabigail

https://sourceware.org/bugzilla/show_bug.cgi?id=19204

dodji at redhat dot com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |ASSIGNED

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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

* [Bug default/19204] assert in ../../src/abg-dwarf-reader.cc:5870
  2015-01-01  0:00 [Bug default/19204] New: assert in ../../src/abg-dwarf-reader.cc:5870 woodard at redhat dot com
                   ` (6 preceding siblings ...)
  2016-01-01  0:00 ` [Bug default/19204] libabigail aborts on DWARF referencing non-existing DIE dodji at redhat dot com
@ 2016-01-01  0:00 ` woodard at redhat dot com
  7 siblings, 0 replies; 9+ messages in thread
From: woodard at redhat dot com @ 2016-01-01  0:00 UTC (permalink / raw)
  To: libabigail

https://sourceware.org/bugzilla/show_bug.cgi?id=19204

--- Comment #3 from Ben Woodard <woodard at redhat dot com> ---
I've been looking at the data from the latest run and we actually have two
incidents of this and both of them were created with the XLC 12.1 compiler.
Therefore I think that it is rather unlikely that it is just a corrupted
binary. Rather I think it is more likely a bug in the XLC 12.1 compiler.

When the data is corrupt, if we can just exit gracefully that would be fine.

hype356@ben:cat
collab/usr/global/tools/gperftools/2.4/bgqos_0/xlc@12.1/lib/libtcmalloc.so.4.2.6/stderr
collab/usr/global/tools/gperftools/2.4/bgqos_0/xlc@12.1/lib/libtcmalloc_and_profiler.so.4.2.6/stderr
abidw: ../../src/abg-dwarf-reader.cc:6212: void
abigail::dwarf_reader::get_parent_die(abigail::dwarf_reader::read_context&,
Dwarf_Die*, bool, Dwarf_Die&, size_t): Assertion `i !=
ctxt.die_parent_map().end()' failed.
abidw: ../../src/abg-dwarf-reader.cc:6212: void
abigail::dwarf_reader::get_parent_die(abigail::dwarf_reader::read_context&,
Dwarf_Die*, bool, Dwarf_Die&, size_t): Assertion `i !=
ctxt.die_parent_map().end()' failed.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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

* [Bug default/19204] assert in ../../src/abg-dwarf-reader.cc:5870
  2015-01-01  0:00 [Bug default/19204] New: assert in ../../src/abg-dwarf-reader.cc:5870 woodard at redhat dot com
@ 2016-01-01  0:00 ` woodard at redhat dot com
  2016-01-01  0:00 ` [Bug default/19204] libabigail aborts on DWARF referencing non-existing DIE dodji at redhat dot com
                   ` (6 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: woodard at redhat dot com @ 2016-01-01  0:00 UTC (permalink / raw)
  To: libabigail

https://sourceware.org/bugzilla/show_bug.cgi?id=19204

--- Comment #2 from Ben Woodard <woodard at redhat dot com> ---
This still happens with the current git up through
11c89cad3e94840f0cab715efbea01acf613bbf4

hype356@ben:~/bin/abidw --abidiff
/collab/usr/global/tools/gperftools/2.4/bgqos_0/xlc@12.1/lib/libtcmalloc.so.4.2.6
abidw: ../../src/abg-dwarf-reader.cc:6212: void
abigail::dwarf_reader::get_parent_die(abigail::dwarf_reader::read_context&,
Dwarf_Die*, bool, Dwarf_Die&, size_t): Assertion `i !=
ctxt.die_parent_map().end()' failed.
Aborted (core dumped)

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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

* [Bug default/19204] libabigail aborts on DWARF referencing non-existing DIE
  2015-01-01  0:00 [Bug default/19204] New: assert in ../../src/abg-dwarf-reader.cc:5870 woodard at redhat dot com
                   ` (2 preceding siblings ...)
  2016-01-01  0:00 ` [Bug default/19204] assert in ../../src/abg-dwarf-reader.cc:5870 dodji at redhat dot com
@ 2016-01-01  0:00 ` dodji at redhat dot com
  2016-01-01  0:00 ` dodji at redhat dot com
                   ` (3 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: dodji at redhat dot com @ 2016-01-01  0:00 UTC (permalink / raw)
  To: libabigail

https://sourceware.org/bugzilla/show_bug.cgi?id=19204

--- Comment #4 from dodji at redhat dot com ---
Created attachment 8913
  --> https://sourceware.org/bugzilla/attachment.cgi?id=8913&action=edit
Text representation of the DWARF debug info of libtcmalloc.so.4.2.6 attached
earlier

I believe the root cause of why libabigail's DWARF reader is choking on this
libtcmalloc.so.4.2.6 binary (built using the XLC 12.1.0.11 version for Blue
Gene) is that the debug info is not correct.

So I am attaching that debug info here so that people can see what I am talking
about.

This DWARF debug info has been obtained by doing:

  eu-readelf --debug-dump=info libtcmalloc.so.4.2.6 >
libtcmalloc.so.4.2.6.dwarf

It looks like this debug info was generated by the XLC compiler, version
12.1.0.11, as we can see by reading it:

  producer             (string) "IBM XL C/C++ for Blue Gene, Version 12.1.0.11"

I believe the debug info has at least a flaw that should be reported to the
relevant XLC team:

Look at the DIE below:


 [ 8a26a]        member
                 name                 (string) "call_stack"
                 accessibility        (data1) public (1)
                 data_member_location (block1) 
                  [   0] plus_uconst 24
                 type                 (ref8) [ 84e09]

Note how the "type" attribute refers to a DIE of offset '84e09'.

The problem is that there is no DIE with offset 84e09 in the debug info file!

So, the DIE above refers to a non-existing DIE.  And I believe that's a bug
that ought be fixed.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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

* [Bug default/19204] libabigail aborts on DWARF referencing non-existing DIE
  2015-01-01  0:00 [Bug default/19204] New: assert in ../../src/abg-dwarf-reader.cc:5870 woodard at redhat dot com
  2016-01-01  0:00 ` [Bug default/19204] " woodard at redhat dot com
@ 2016-01-01  0:00 ` dodji at redhat dot com
  2016-01-01  0:00 ` [Bug default/19204] assert in ../../src/abg-dwarf-reader.cc:5870 dodji at redhat dot com
                   ` (5 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: dodji at redhat dot com @ 2016-01-01  0:00 UTC (permalink / raw)
  To: libabigail

https://sourceware.org/bugzilla/show_bug.cgi?id=19204

dodji at redhat dot com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|assert in                   |libabigail aborts on DWARF
                   |../../src/abg-dwarf-reader. |referencing non-existing
                   |cc:5870                     |DIE

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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

* [Bug default/19204] libabigail aborts on DWARF referencing non-existing DIE
  2015-01-01  0:00 [Bug default/19204] New: assert in ../../src/abg-dwarf-reader.cc:5870 woodard at redhat dot com
                   ` (5 preceding siblings ...)
  2016-01-01  0:00 ` [Bug default/19204] assert in ../../src/abg-dwarf-reader.cc:5870 woodard at redhat dot com
@ 2016-01-01  0:00 ` dodji at redhat dot com
  2016-01-01  0:00 ` [Bug default/19204] assert in ../../src/abg-dwarf-reader.cc:5870 woodard at redhat dot com
  7 siblings, 0 replies; 9+ messages in thread
From: dodji at redhat dot com @ 2016-01-01  0:00 UTC (permalink / raw)
  To: libabigail

https://sourceware.org/bugzilla/show_bug.cgi?id=19204

dodji at redhat dot com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|---                         |FIXED

--- Comment #5 from dodji at redhat dot com ---
This issue should be fixed in libabigail by commit
https://sourceware.org/git/gitweb.cgi?p=libabigail.git;a=commit;h=066ebbdf0e868136ff22735942e28321fa7bd0d1
in the master branch of the repository.

Thanks for filing this bug!

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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

* [Bug default/19204] libabigail aborts on DWARF referencing non-existing DIE
  2015-01-01  0:00 [Bug default/19204] New: assert in ../../src/abg-dwarf-reader.cc:5870 woodard at redhat dot com
                   ` (3 preceding siblings ...)
  2016-01-01  0:00 ` [Bug default/19204] libabigail aborts on DWARF referencing non-existing DIE dodji at redhat dot com
@ 2016-01-01  0:00 ` dodji at redhat dot com
  2016-01-01  0:00 ` [Bug default/19204] assert in ../../src/abg-dwarf-reader.cc:5870 woodard at redhat dot com
                   ` (2 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: dodji at redhat dot com @ 2016-01-01  0:00 UTC (permalink / raw)
  To: libabigail

https://sourceware.org/bugzilla/show_bug.cgi?id=19204

--- Comment #6 from dodji at redhat dot com ---
> Look at the DIE below:
>
>
>  [ 8a26a]        member
>                  name                 (string) "call_stack"
>                  accessibility        (data1) public (1)
>                  data_member_location (block1) 
>                   [   0] plus_uconst 24
>                  type                 (ref8) [ 84e09]
>
> Note how the "type" attribute refers to a DIE of offset '84e09'.
>
> The problem is that there is no DIE with offset 84e09 in the debug info file!

I wanted to add that the offending DIE at offset 0x8a26a (which
references the the non-existing DIE 0x84e09) comes from the translation
unit "../gperftools-2.4/src/memory_region_map.cc", built from directory
"/g/g0/legendre/tools/gperftools/bgq_xlc_build".

This info comes from look at the debug info for the compilation unit
which which contains DIE 8a26a:

---------------------------------->8<--------------------------------------
Compilation unit at offset 544265:
Version: 2, Abbreviation section offset: 13740, Address size: 8, Offset size: 8
[ 84e20]  compile_unit
          name                 (string)
"../gperftools-2.4/src/memory_region_map.cc"
          stmt_list            (data8) 84147
          low_pc               (addr) +0x00000000000c8260
          high_pc              (addr) +0x00000000000d0c24
          language             (data1) C_plus_plus (4)
          comp_dir             (string)
"/g/g0/legendre/tools/gperftools/bgq_xlc_build"
---------------------------------->8<--------------------------------------

So if we are to submit the issue to the compiler folks, we'd probably
need to provide them with the preprocessed output of the file
gperftools-2.4/src/memory_region_map.cc as well as the resulting *.o
binary, compiled with debug info generation turned on, and on which we'd
have made sure to see the DIE for the "LockHolder::call_stack" data
member which references a type DIE which is not present in the debug
info.  Or maybe it's present in the *.o file and it's the linker which
wrongly removes it later?

Anyway, food for thought (and investigation).

-- 
You are receiving this mail because:
You are on the CC list for the bug.

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

end of thread, other threads:[~2016-01-21 11:25 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-01-01  0:00 [Bug default/19204] New: assert in ../../src/abg-dwarf-reader.cc:5870 woodard at redhat dot com
2016-01-01  0:00 ` [Bug default/19204] " woodard at redhat dot com
2016-01-01  0:00 ` [Bug default/19204] libabigail aborts on DWARF referencing non-existing DIE dodji at redhat dot com
2016-01-01  0:00 ` [Bug default/19204] assert in ../../src/abg-dwarf-reader.cc:5870 dodji at redhat dot com
2016-01-01  0:00 ` [Bug default/19204] libabigail aborts on DWARF referencing non-existing DIE dodji at redhat dot com
2016-01-01  0:00 ` dodji at redhat dot com
2016-01-01  0:00 ` [Bug default/19204] assert in ../../src/abg-dwarf-reader.cc:5870 woodard at redhat dot com
2016-01-01  0:00 ` [Bug default/19204] libabigail aborts on DWARF referencing non-existing DIE dodji at redhat dot com
2016-01-01  0:00 ` [Bug default/19204] assert in ../../src/abg-dwarf-reader.cc:5870 woodard at redhat dot com

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).