mirror of
git://sourceware.org/git/libabigail.git
synced 2025-03-06 14:47:32 +00:00
The Git repository of the Libabigail Project
Kernel v5.4 introduces Symbol Namespaces [1]. That changes the layout of ksymtab entries in Kernel binaries. In particular, the kernel_symbol entry gains a new member to represent the namespace. That change affects binaries that have position relative relocations (we name that format here V4_19_KSYMTAB_FORMAT) as well as those that don't (PRE_V4_19_KSYMTAB_FORMAT). In any case there is an additional entry that has the same size as the previous entries. Since we iterate over the ksymtab entries to collect them, we need to determine the correct size of these entries even though we do not grab the namespace for ABI analysis purposes at this time. In order to determine the size, we attempt to find the beginning of the next entry by trying to read symbols with an increasing offset. Once we succeed, we have the offset and therefore the size of one entry. Since try_reading_first_ksymtab_entry() does already everything we need to attempt to read a symbol from a beginning of a ksymtab, we only needed to teach it to operate on an offset to read the potential second entry. 'load_kernel_symbol_table' was determining the number of entries unconditionally, even when we do have the unsupported case of a ksymtab with relocations. Hence only load when needed. * src/abg-dwarf-reader.cc (read_context::try_reading_first_ksymtab_entry): Add symbol_offset parameter. (read_context::get_ksymtab_entry_size): Add support for variable size ksymtab entries due to symbol namespaces. (load_kernel_symbol_table): only load nb_entries when needed [1] https://lore.kernel.org/lkml/20190906103235.197072-1-maennich@google.com/ Signed-off-by: Matthias Maennich <maennich@google.com> |
||
---|---|---|
autoconf-archive | ||
bash-completion | ||
doc | ||
include | ||
m4 | ||
scripts | ||
src | ||
tests | ||
tools | ||
.clang-format | ||
.gitignore | ||
abigail.m4 | ||
AUTHORS | ||
ChangeLog | ||
COMMIT-LOG-GUIDELINES | ||
COMPILING | ||
configure.ac | ||
CONTRIBUTING | ||
COPYING | ||
COPYING-GPLV3 | ||
COPYING-LGPLV2 | ||
COPYING-LGPLV3 | ||
default.abignore | ||
gen-changelog.py | ||
install-sh | ||
libabigail.pc.in | ||
ltmain.sh | ||
Makefile.am | ||
NEWS | ||
README | ||
release-text-template.txt | ||
update-copyright.sh | ||
VISIBILITY |
This is the Application Binary Interface Generic Analysis and Instrumentation Library. It aims at constructing, manipulating, serializing and de-serializing ABI-relevant artifacts. The set of artifacts that we are intersted is made of quantities like types, variable, fonctions and declarations of a given library or program. For a given library or program this set of quantities is called an ABI corpus. This library aims at (among other things) providing a way to compare two ABI Corpora (apparently the plural of corpus is copora, heh, that's cool), provide detailed information about their differences, and help build tools to infer interesting conclusions about these differences. You are welcome to contribute to this project after reading the files CONTRIBUTING and COMMIT-LOG-GUIDELINES files in the source tree. Communicating with the maintainers of this project -- including sending patches to be include to the source code -- happens via email at libabigail@sourceware.org.