Re: [PATCH] x86/kbuild: enable modversions for symbols exported from asm

From: Stanislav Kozina
Date: Mon Dec 12 2016 - 20:08:11 EST


Hello,

That said, a dwarf based checker tool should be able to do as good a job
(maybe a bit better because report is very informative and it may pick up
compiler alignments or padding options).
So, Nicholas was kind enough to send me the two Linux Kernel binaries
that he built with the tiny little interface change that we were
discussing earlier. Here is what the abidiff[1] tools says about that
interface change:

Thanks Nicholas and Dodji for this great example, for comparison I think it would be nice to share the example run with kabi-dw too.
kabi-dw first dumps and unifies all type information into a set of text files, the unification takes a significant time. Then the two sets of these text files can be compared.

An example run would look like:
$ time ~/Code/kabi-dw/kabi-dw generate -o abi1 vmlinux.abi1
Generating symbol defs from vmlinux.abi1...

real 0m29.057s
user 0m13.929s
sys 0m14.862s
$ time ~/Code/kabi-dw/kabi-dw generate -o abi2 vmlinux.abi2
Generating symbol defs from vmlinux.abi2...

real 0m29.134s
user 0m13.961s
sys 0m14.921s
$ time ~/Code/kabi-dw/kabi-dw compare abi1 abi2
Changes detected in: home/npiggin/src/linux.vectors/mm/memory.c/struct--blah.txt
Inserted:
+0x0 int y;
Shifted:
-0x0 int x;
+0x4 int x;


real 0m0.176s
user 0m0.135s
sys 0m0.040s

The size of the generated text files with all the relevant type information is as follows:
$ du -hs abi1
16M abi1
$ find abi1 -type f | wc -l
3162

Warm regards,
-Stanislav