In a compiler I'm working on, the last stage of the compilation consists in
calling objcopy --strip-symbols to remove some auxiliary symbols from the
resulting object file.
In a particular run, I was annoyed to observe that objcopy needed 1m15s to
complete. The size of the object file before stripping was 2377628 bytes, and
the symbol list file contained 31285 symbols.
The problem is that is_specified_symbol() walks a list. The attached patch fixes
that by storing symbol names in hash sets rather than in lists. objcopy now
processes the same data in 284 milliseconds.
Notes:
- obviously, there is no performance gain when the --wildcard option is used
- I did not bother fixing the performance of redefine_sym_list
--
Summary: severe performance issue in objcopy symbol filtering
code
Product: binutils
Version: unspecified
Status: NEW
Severity: normal
Priority: P2
Component: binutils
AssignedTo: unassigned at sources dot redhat dot com
ReportedBy: jylefort at brutele dot be
CC: bug-binutils at gnu dot org
http://sourceware.org/bugzilla/show_bug.cgi?id=6034
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
_______________________________________________
bug-binutils mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/bug-binutils