https://sourceware.org/bugzilla/show_bug.cgi?id=31763
Mark Wielaard <mark at klomp dot org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |mark at klomp dot org
--- Comment #1 from Mark Wielaard <mark at klomp dot org> ---
Hohum. The slowdown comes from the fact that eu-readelf by default tries to do
an symbol lookup for every address it tries to print the function symbol +
offset.
The idea is that the -r output would look something like:
Relocation section [12] '.relr.dyn' at offset 0x4bc88 contains 750 entries:
+0x000000000044bcd0 <__frame_dummy_init_array_entry> *
+0x000000000044bcd8 <__do_global_dtors_aux_fini_array_entry>
+0x000000000044bce0 <__dso_handle>
+0x000000000044bd10 <ossl_ed448_asn1_meth+0x10>
+0x000000000044bd18 <ossl_ed448_asn1_meth+0x18>
+0x000000000044bd20 <ossl_ed448_asn1_meth+0x20>
[...]
But in practice this doesn't actually work for system libraries, since the
.symtab is stripped out, so the symbol lookup always fails (even with debuginfo
installed, since readelf doesn't do a separate .debug file lookup, you'll have
to eu-unstrip the library and debug file). It is super useful for your locally
build binaries though.
Unfortunately even with the .symtab stripped out this symbol lookup is
unreasonably slow.
As a workaround you can use:
-N, --numeric-addresses Do not find symbol names for addresses in DWARF
data
$ time eu-readelf -r ./libcrypto.so.3 | wc -l
17904
real 0m6.676s
user 0m6.648s
sys 0m0.010s
$ time eu-readelf -r -N ./libcrypto.so.3 | wc -l
17904
real 0m0.045s
user 0m0.037s
sys 0m0.013s
--
You are receiving this mail because:
You are on the CC list for the bug.