[PATCH] D49164: Parallelize GdbIndexSection's symbol table creation.
Rui Ueyama via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jul 10 17:50:51 PDT 2018
ruiu created this revision.
ruiu added a reviewer: grimar.
Herald added subscribers: arichardson, emaste.
Herald added a reviewer: espindola.
Since .gdb_index sections contain all known symbols, they can be very large.
One of my executable has a .gdb_index section of 1350 GiB. Uniquifying
symbols by name takes 3.77 seconds on my machine. This patch parallelize it.
Time to call createSymbols() with 8.4 million unique symbols:
Without this patch: 3773 ms
Parallelism = 1: 4374 ms
Parallelism = 2: 2628 ms
Parallelism = 16: 837 ms
As you can see above, this algorithm is a bit more inefficient
than the non-parallelized version, but even with dual-core, it is
faster than that, so I think it is overall a win.
https://reviews.llvm.org/D49164
Files:
lld/ELF/SyntheticSections.cpp
lld/test/ELF/gdb-index.s
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D49164.154909.patch
Type: text/x-patch
Size: 4497 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180711/28e3eee2/attachment.bin>
More information about the llvm-commits
mailing list