libabigail/tests
Dodji Seketeli 2f7248f340 PR25058 - Support decl DIEs referring to symbols using DW_AT_ranges
Usually, function DIEs (DW_TAG_subprogram) refer to the address of the
underlying ELF symbol by using the DW_AT_low_pc attribute.  However,
there are cases where it does so by using the DW_AT_ranges attribute.
In those cases, the first address of the sequence defined in the value
of that attribute is the address of the ELF symbol.

The problem is that the DWARF reader of Libabigail fails to get the
address of the underlying ELF symbol when the DW_AT_low_pc attribute
is missing.  Rather, it should then look at the value of the
DW_AT_ranges attribute instead.

This is what this patch does.

	* src/abg-dwarf-reader.cc
	(read_context::get_first_address_from_DW_AT_ranges): Define new
	member function.
	(read_context::get_function_address): Use the new
	read_context::get_first_address_from_DW_AT_ranges here.
	* tests/data/test-diff-dwarf/PR25058-liblttng-ctl-report-1.txt:
	New reference test output.
	* tests/data/test-diff-dwarf/PR25058-liblttng-ctl.so: New test
	input binary.
	* tests/data/test-diff-dwarf/PR25058-liblttng-ctl2.10.so: New test
	input binary.
	* tests/data/Makefile.am: Add the new test materials above to
	source distribution.
	* tests/test-diff-dwarf.cc (in_out_specs): Add the new input test
	input binary files to this test harness.

Signed-off-by: Dodji Seketeli <dodji@redhat.com>
2019-10-03 17:42:30 +02:00
..
data PR25058 - Support decl DIEs referring to symbols using DW_AT_ranges 2019-10-03 17:42:30 +02:00
.gitignore Update tests/.gitignore to ignore runtesttoolsutils 2019-07-09 17:33:58 +02:00
Makefile.am Ensure a consistent C++ standard use 2019-07-22 11:18:13 +02:00
mockfedabipkgdiff.in Bug 22722 - Make fedabipkgdiff and its tests support both python 3 and 2 2018-03-29 13:46:50 +02:00
print-diff-tree.cc abilint: fix return types bool -> int 2019-04-16 16:11:01 +02:00
runtestcanonicalizetypes.sh.in Bug 20180 - Support system-wide suppression specifications 2016-05-30 18:39:49 +02:00
runtestdefaultsupprs.py.in Fix typo in tests/runtestdefaultsupprs.py 2018-05-24 10:48:56 +02:00
runtestdefaultsupprspy3.sh.in Bug 22722 - Make fedabipkgdiff and its tests support both python 3 and 2 2018-03-29 13:46:50 +02:00
runtestfedabipkgdiff.py.in Bug 22722 - Make fedabipkgdiff and its tests support both python 3 and 2 2018-03-29 13:46:50 +02:00
runtestfedabipkgdiffpy3.sh.in Bug 22722 - Make fedabipkgdiff and its tests support both python 3 and 2 2018-03-29 13:46:50 +02:00
test-abicompat.cc Update copyright for 2019 2019-01-07 14:54:47 +01:00
test-abidiff-exit.cc Update copyright for 2019 2019-01-07 14:54:47 +01:00
test-abidiff.cc Bug 24552 - abidiff fails comparing a corpus against a corpus group 2019-05-16 18:10:08 +02:00
test-alt-dwarf-file.cc Update copyright for 2019 2019-01-07 14:54:47 +01:00
test-annotate.cc Handle several member anonymous types of the same kind 2019-05-07 14:31:16 +02:00
test-core-diff.cc Update copyright for 2019 2019-01-07 14:54:47 +01:00
test-diff2.cc Update copyright for 2019 2019-01-07 14:54:47 +01:00
test-diff-dwarf-abixml.cc Update copyright for 2019 2019-01-07 14:54:47 +01:00
test-diff-dwarf.cc PR25058 - Support decl DIEs referring to symbols using DW_AT_ranges 2019-10-03 17:42:30 +02:00
test-diff-filter.cc Bug 24787 - Filter out enum changes into compatible integer types 2019-07-19 18:22:12 +02:00
test-diff-pkg.cc Add compatibility layer for C++11 mode 2019-07-09 18:05:28 +02:00
test-diff-suppr.cc Support the "name_not_regexp" property in the [suppress_type] section 2019-09-30 14:56:52 +02:00
test-dot.cc Correct DOT merge. 2013-07-23 23:13:55 +02:00
test-ini.cc Update copyright for 2019 2019-01-07 14:54:47 +01:00
test-ir-walker.cc Update copyright for 2019 2019-01-07 14:54:47 +01:00
test-lookup-syms.cc Update copyright for 2019 2019-01-07 14:54:47 +01:00
test-read-dwarf.cc PR25042 - Support string form DW_FORM_strx{1,4} from DWARF 5 2019-10-01 14:14:41 +02:00
test-read-write.cc Add compatibility layer for C++11 mode 2019-07-09 18:05:28 +02:00
test-svg.cc Add svg generation. 2013-07-23 23:13:54 +02:00
test-tools-utils.cc Fully account for anonymous-ness of scopes when comparing decl names 2019-06-21 11:42:44 +02:00
test-types-stability.cc Add compatibility layer for C++11 mode 2019-07-09 18:05:28 +02:00
test-utils.cc Update copyright for 2019 2019-01-07 14:54:47 +01:00
test-utils.h Conditionalize the Rust support regression test 2019-01-24 11:06:57 +01:00
test-valgrind-suppressions.supp Shut down a helgrind false positive in the "system" libc call 2017-03-17 09:02:19 +01:00
test-write-read-archive.cc Add compatibility layer for C++11 mode 2019-07-09 18:05:28 +02:00
update-test-output.py Rename tests/update-test-read-dwarf-output.py 2016-12-02 12:59:32 +01:00