OSDN Git Service

[COFF] Process /EXPORT option in fastpath
authorRui Ueyama <ruiu@google.com>
Tue, 9 Jan 2018 20:36:42 +0000 (20:36 +0000)
committerRui Ueyama <ruiu@google.com>
Tue, 9 Jan 2018 20:36:42 +0000 (20:36 +0000)
commitb763cd8c4934d662a06bcedc8859b33e95f452b8
tree20e94936bf613412c9b25505cddcc9a7560c333a
parent41985cbc8e0de532a118c6f57dc59fbf51869e2f
[COFF] Process /EXPORT option in fastpath

Patch by Takuto Ikuta.

This patch reduces lld link time of chromium's blink_core.dll in
component build.

Total size of input argument in .directives become nearly 300MB in the
build and almost all its content are /EXPORT.

To reduce time of parsing too many /EXPORT option in the build, I
introduce fastpath for /EXPORT in ArgParser::parseDirectives.

On my desktop machine, 4 times stats of the link time are like below.
Improved around 20%.

This patch
TotalSeconds : 8.6217627
TotalSeconds : 8.5402175
TotalSeconds : 8.6855853
TotalSeconds : 8.3624441
Ave : 8.5525024

master
TotalSeconds : 10.9975031
TotalSeconds : 11.3409428
TotalSeconds : 10.6332897
TotalSeconds : 10.7650687
Ave : 10.934201075

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@322117 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/Option/ArgList.h