Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
46 commits
Select commit Hold shift + click to select a range
ebb2436
Drop unintentionally added code
metti Aug 11, 2020
cef0561
KMI Whitelists: allow alternative section suffix 'symbol_list'
metti Aug 28, 2020
005ab5c
Use flat representation to canonicalize anonymous classes and unions
Sep 8, 2020
5cf2473
writer: Avoid using dynamic hashing in type maps
Sep 8, 2020
94f5d4a
Merge branch 'master' into mm-next
metti Sep 11, 2020
a434894
Fix thinko in get_vmlinux_path_from_kernel_dist
Sep 14, 2020
3d7916c
Bug 26309 - Wrong leaf reporting of changes to typedef underlying type
Sep 14, 2020
ee2b54d
Make abidiff and abidw support several --headers-dir{1,2} options
Sep 2, 2020
d3bd521
Merge branch 'master' into mm-next
metti Sep 18, 2020
441ea7c
abg-corpus.cc: report architecture discrepancies
myxoid Sep 18, 2020
59610d5
Bug 26568 - Union should support more than one anonymous member
Sep 16, 2020
1dca710
dwarf-reader: sort the types for canonicalization
myxoid Sep 22, 2020
ebaf330
abg-corpus.cc: report architecture discrepancies
myxoid Sep 18, 2020
98bbf30
Merge branch 'master' into 'mm-next'
metti Sep 25, 2020
1ab36e0
Add missing newlines to end of test files.
myxoid Aug 17, 2020
b96040e
Fix two wrongs in test suppression regex
myxoid Aug 17, 2020
2f92777
Consider the implicit 'this' parameter when comparing methods
Oct 8, 2020
fd0f3ac
Fix redundancy detection in the diff graph
Oct 12, 2020
470e10f
Structurally compare the few non-canonicalized types in general
Oct 13, 2020
8d7ffe3
configure: Support ABIGAIL_NO_OPTIMIZATION_DEBUG environment variable
Oct 13, 2020
12ece30
abg-writer.cc: fix write_elf_symbol_reference loop
myxoid Oct 15, 2020
3734479
Merge branch 'master' into 'mm-next'
metti Oct 14, 2020
bed20e0
Update mm-next patch series
metti Oct 14, 2020
264fb4e
comp-filter: Consider CRC changes harmful
metti Oct 15, 2020
247f50d
abg-tools-utils: Fix comment
Oct 23, 2020
ee059a9
dwarf-reader: get subrange_type bounds signedness from underlying type
Oct 23, 2020
67db22f
Assume subrange bounds types are unsigned if no underlying type is gi…
Oct 27, 2020
5e6ceca
Stabilise sort of canonical types
myxoid Oct 28, 2020
a6401af
Improve and stabilise sort of member functions
myxoid Oct 28, 2020
687a2af
Improve enum synthetic type names
myxoid Oct 28, 2020
3f9a176
dwarf-reader: Ignore zero length location expressions from DW_AT_loca…
metti Oct 20, 2020
5c31eaf
dwarf-reader: fix lookup for repeated translation unit paths
metti Oct 21, 2020
f8ef195
Stabilise sort of canonical types
myxoid Oct 21, 2020
4f93fed
dwarf-reader: fix lookup for repeated translation unit paths
metti Oct 21, 2020
b7ad7f2
Bug 26770 - Spurious declaration-only-ness induces spurious type changes
Oct 31, 2020
b4ec629
update-test-output.py: Update syntax
Nov 1, 2020
32343f8
Improve and stabilise sort of member functions
myxoid Oct 29, 2020
8a0825e
Improve enum synthetic type names
myxoid Oct 29, 2020
38e72b2
dwarf-reader: Ignore zero length location expressions from DW_AT_loca…
metti Oct 29, 2020
baee817
Update test-libandroid.so.abi
Nov 3, 2020
3c87247
Bug PR26739 - Handle qualified typedef array types
Oct 27, 2020
2cc1ab7
writer: Sort decls and fix topological sorting for types
Nov 12, 2020
2011191
Merge branch master into mm-next
metti Nov 19, 2020
2011195
abg-ir.cc: improve update_main_alias
myxoid Nov 19, 2020
494e661
ir: Add better comments to types_have_similar_structure
Dec 4, 2020
201207d
ir: Arrays are indirect types for type similarity purposes
Dec 7, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -626,6 +626,11 @@ if test x$ABIGAIL_DEBUG != x; then
CXXFLAGS="$CXXFLAGS -Og -g3 -ggdb"
fi

if test x$ABIGAIL_NO_OPTIMIZATION_DEBUG != x; then
CFLAGS="-g -O0 -Wall -Wextra -Werror"
CXXFLAGS="-g -O0 -Wall -Wextra -Werror"
fi

if test x$ENABLE_ASAN = xyes; then
CFLAGS="$CFLAGS -fsanitize=address"
CXXFLAGS="$CXXFLAGS -fsanitize=address"
Expand Down
23 changes: 21 additions & 2 deletions doc/manuals/abidiff.rst
Original file line number Diff line number Diff line change
Expand Up @@ -101,8 +101,18 @@ Options
* ``--headers-dir1 | --hd1`` <headers-directory-path-1>

Specifies where to find the public headers of the first shared
library that the tool has to consider. The tool will thus filter
out ABI changes on types that are not defined in public headers.
library (or binary in general) that the tool has to consider. The
tool will thus filter out ABI changes on types that are not
defined in public headers.

Note that several public header directories can be specified for
the first shared library. In that case the ``--headers-dir1``
option should be present several times on the command line, like
in the following example: ::

$ abidiff --headers-dir1 /some/path \
--headers-dir1 /some/other/path \
binary-version-1 binary-version-2

* ``--header-file1 | --hf1`` <header-file-path-1>

Expand All @@ -116,6 +126,15 @@ Options
library that the tool has to consider. The tool will thus filter
out ABI changes on types that are not defined in public headers.

Note that several public header directories can be specified for
the second shared library. In that case the ``--headers-dir2``
option should be present several times like in the following
example: ::

$ abidiff --headers-dir2 /some/path \
--headers-dir2 /some/other/path \
binary-version-1 binary-version-2

* ``--header-file2 | --hf2`` <header-file-path-2>

Specifies where to find one public header of the second shared
Expand Down
15 changes: 12 additions & 3 deletions doc/manuals/abidw.rst
Original file line number Diff line number Diff line change
Expand Up @@ -128,9 +128,18 @@ Options

* ``--headers-dir | --hd`` <headers-directory-path-1>

Specifies where to find the public headers of the first shared
library that the tool has to consider. The tool will thus filter
out types that are not defined in public headers.
Specifies where to find the public headers of the binary that the
tool has to consider. The tool will thus filter out types that
are not defined in public headers.

Note that several public header directories can be specified for
the binary to consider. In that case the ``--header-dir`` option
should be present several times on the command line, like in the
following example: ::

$ abidw --header-dir /some/path \
--header-dir /some/other/path \
binary > binary.abi

* ``--header-file | --hf`` <header-file-path>

Expand Down
17 changes: 8 additions & 9 deletions doc/manuals/kmidiff.rst
Original file line number Diff line number Diff line change
Expand Up @@ -70,23 +70,22 @@ functions and variables) between the Kernel and its modules. In
practice, though, users want to compare a subset of the those
interfaces.

Users can then define a "white list" of the interfaces to compare.
Such a white list is a just a file in the "INI" format that looks
like: ::
Users can then define a "symbol list" of the interfaces to compare.
Such a list is a just a file in the "INI" format that looks like: ::

[kernel_version_x86_64_whitelist]
[kernel_version_x86_64_symbol_list]
function1_name
function2_name
global_variable1_name
....


Note that the name of the section (the name that is between the two
brackets) of that INI file just has to end with the string
"whitelist". So you can define the name you want, for instance
``[kernel_46_x86_64_whitelist]``.
Note that the name of the section (the name that is between the two brackets)
of that INI file just has to end with the string "symbol_list" or "whitelist".
So you can define the name you want, for instance
``[kernel_46_x86_64_symbol_list]``.

Then each line of that whitelist file is the name of an exported
Then each line of that symbol list file is the name of an exported
function or variable. Only those interfaces along with the types
reachable from their signatures are going to be compared by
``kmidiff`` recursively.
Expand Down
20 changes: 19 additions & 1 deletion include/abg-fwd.h
Original file line number Diff line number Diff line change
Expand Up @@ -703,11 +703,14 @@ array_type_def_sptr
is_array_type(const type_or_decl_base_sptr& decl);

array_type_def_sptr
is_array_of_qualified_element(type_base_sptr&);
is_array_of_qualified_element(const type_base_sptr&);

qualified_type_def_sptr
is_array_of_qualified_element(const array_type_def_sptr&);

array_type_def_sptr
is_typedef_of_array(const type_base_sptr&);

void
set_data_member_offset(var_decl_sptr, uint64_t);

Expand Down Expand Up @@ -848,6 +851,9 @@ peel_qualified_type(const type_base_sptr&);
type_base*
peel_qualified_or_typedef_type(const type_base* type);

type_base_sptr
peel_qualified_or_typedef_type(const type_base_sptr &type);

type_base_sptr
peel_typedef_pointer_or_reference_type(const type_base_sptr);

Expand All @@ -858,6 +864,18 @@ type_base*
peel_pointer_or_reference_type(const type_base *type,
bool peel_qualified_type = true);

array_type_def_sptr
clone_array(const array_type_def_sptr& array);

typedef_decl_sptr
clone_typedef(const typedef_decl_sptr& t);

qualified_type_def_sptr
clone_qualified_type(const qualified_type_def_sptr& t);

type_base_sptr
clone_array_tree(const type_base_sptr t);

string
get_name(const type_or_decl_base*, bool qualified = true);

Expand Down
14 changes: 13 additions & 1 deletion include/abg-ir.h
Original file line number Diff line number Diff line change
Expand Up @@ -1736,6 +1736,9 @@ class scope_decl : public virtual decl_base
declarations&
get_member_decls();

const declarations&
get_sorted_member_decls() const;

virtual size_t
get_num_anonymous_member_classes() const;

Expand Down Expand Up @@ -2112,6 +2115,9 @@ class qualified_type_def : public virtual type_base, public virtual decl_base
type_base_sptr
get_underlying_type() const;

void
set_underlying_type(const type_base_sptr&);

virtual void
get_qualified_name(interned_string& qualified_name,
bool internal = false) const;
Expand Down Expand Up @@ -2356,7 +2362,7 @@ class array_type_def : public virtual type_base, public virtual decl_base
const string& name,
bound_value lower_bound,
bound_value upper_bound,
type_base_sptr& underlying_type,
const type_base_sptr& underlying_type,
const location& loc,
translation_unit::language l = translation_unit::LANG_C11);

Expand Down Expand Up @@ -2675,6 +2681,9 @@ class typedef_decl : public virtual type_base, public virtual decl_base
type_base_sptr
get_underlying_type() const;

void
set_underlying_type(const type_base_sptr&);

virtual bool
traverse(ir_node_visitor&);

Expand Down Expand Up @@ -3177,6 +3186,9 @@ class function_type : public virtual type_base
parameters::const_iterator
get_first_non_implicit_parm() const;

parameters::const_iterator
get_first_parm() const;

const interned_string&
get_cached_name(bool internal = false) const;

Expand Down
6 changes: 3 additions & 3 deletions include/abg-reporter.h
Original file line number Diff line number Diff line change
Expand Up @@ -175,9 +175,9 @@ class default_reporter : public reporter_base
const std::string& indent = "") const;

void
report_local_typedef_changes(const typedef_diff &d,
std::ostream& out,
const std::string& indent) const;
report_non_type_typedef_changes(const typedef_diff &d,
std::ostream& out,
const std::string& indent) const;

virtual void
report(const typedef_diff& d, std::ostream& out,
Expand Down
6 changes: 5 additions & 1 deletion include/abg-tools-utils.h
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,10 @@ suppr::type_suppression_sptr
gen_suppr_spec_from_headers(const string& hdrs_root_dir,
const vector<string>& hdr_files);

suppr::type_suppression_sptr
gen_suppr_spec_from_headers(const vector<string>& headers_root_dirs,
const vector<string>& header_files);

suppr::suppressions_type
gen_suppr_spec_from_kernel_abi_whitelists
(const vector<string>& abi_whitelist_paths);
Expand Down Expand Up @@ -218,7 +222,7 @@ enum abidiff_status
/// Its numerical value is 0.
ABIDIFF_OK = 0,

/// This bit is set if there an application error.
/// This bit is set if there is an application error.
///
/// Its numerical value is 1.
ABIDIFF_ERROR = 1,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ index ee8c823964e7..5c1e915ad2f3 100644
string_elf_symbols_map_sptr undefined_fun_symbol_map;
elf_symbols sorted_fun_symbols;
diff --git a/src/abg-corpus.cc b/src/abg-corpus.cc
index 9e90b99473d3..94702047dd82 100644
index 0e8e6d71b15e..3d74b8163f22 100644
--- a/src/abg-corpus.cc
+++ b/src/abg-corpus.cc
@@ -38,6 +38,7 @@ ABG_BEGIN_EXPORT_DECLARATIONS
Expand All @@ -127,7 +127,7 @@ index 9e90b99473d3..94702047dd82 100644
///
/// @param map a shared pointer to the new function symbols map.
diff --git a/src/abg-dwarf-reader.cc b/src/abg-dwarf-reader.cc
index 7c56bd8c4276..788b167db388 100644
index 7257052e6e45..d6e130ad4a74 100644
--- a/src/abg-dwarf-reader.cc
+++ b/src/abg-dwarf-reader.cc
@@ -50,6 +50,7 @@
Expand Down Expand Up @@ -188,15 +188,15 @@ index 7c56bd8c4276..788b167db388 100644
/// Getter for a pointer to the map that associates the address of
/// an entry point of a function with the symbol of that function.
///
@@ -15819,6 +15842,7 @@ read_debug_info_into_corpus(read_context& ctxt)
@@ -15829,6 +15852,7 @@ read_debug_info_into_corpus(read_context& ctxt)
group->add_corpus(ctxt.current_corpus());

// Set symbols information to the corpus.
+ ctxt.current_corpus()->set_symtab(ctxt.symtab());
if (!get_ignore_symbol_table(ctxt))
{
if (ctxt.load_in_linux_kernel_mode()
@@ -17125,6 +17149,9 @@ read_corpus_from_elf(read_context& ctxt, status& status)
@@ -17135,6 +17159,9 @@ read_corpus_from_elf(read_context& ctxt, status& status)
status |= STATUS_NO_SYMBOLS_FOUND;
}

Expand All @@ -207,7 +207,7 @@ index 7c56bd8c4276..788b167db388 100644
status & STATUS_NO_SYMBOLS_FOUND
// ... or if debug info was found but not the required alternate
diff --git a/src/abg-reader.cc b/src/abg-reader.cc
index e72a5de9ac0e..418c037263aa 100644
index 315747389bc7..94ebf3b91db6 100644
--- a/src/abg-reader.cc
+++ b/src/abg-reader.cc
@@ -47,6 +47,7 @@ ABG_BEGIN_EXPORT_DECLARATIONS
Expand Down
Loading