Slow readelf for huge ARM binary
Nicholas Clifton
nickc@redhat.com
Tue Feb 24 15:41:00 GMT 2015
Hi Dmitry,
I have checked your patch in, together with the changelog entry below.
There was one problem however, alluded to by H.J. You changed the
find_symbol_for_address() function to use a binary search and skip the
test for the symbol being a function symbol. But although
find_symbol_for_address is called from several places in readelf.c you
only updated the ARM caller. Other targets, eg IA64 and HPPA were still
passing the old, unsorted, complete symbol table to the function... I
took the liberty of fixing this problem before applying the patch.
Cheers
Nick
binutils/ChangeLog
2015-02-24 Dmitry Antipov <dantipov@nvidia.com>
* readelf.c (find_symbol_for_address): Use a binary search to
speed up symbol location. Skip check for function symbol type.
(*_unw_aux_info): Add funtab and nfuns fields contains a sorted
list of function symbols.
(dump_ia64_unwind): Initialise the funtab and nfuns fields and
pass them to find_symbol_for_address.
(dump_hppa_unwind): Likewise.
(arm_print_vma_and_name): Pass funtab to find_symbol_for_address.
(dump_arm_unwind): Initialise the funtab and nfuns fields.
More information about the Binutils
mailing list