diff options
author | Jonas Devlieghere <jonas@devlieghere.com> | 2018-02-22 09:20:40 +0000 |
---|---|---|
committer | Jonas Devlieghere <jonas@devlieghere.com> | 2018-02-22 09:20:40 +0000 |
commit | 26e943106b5cc6bc08d7c14068ff3526cf9faf9b (patch) | |
tree | f4294b07d27260f2d7914329ebfd88152aba9016 /clang/lib/Frontend/CompilerInvocation.cpp | |
parent | 9a25247f8059ec2f4ffdb774d5bfb2fe698cfa79 (diff) | |
download | bcm5719-llvm-26e943106b5cc6bc08d7c14068ff3526cf9faf9b.tar.gz bcm5719-llvm-26e943106b5cc6bc08d7c14068ff3526cf9faf9b.zip |
[dsymutil] Be smarter in caching calls to realpath
Calling realpath is expensive but necessary to perform the uniqueing in
dsymutil. Although we already cached the results for every individual
file in the line table, we had reports of it taking 40 seconds of a 3.5
minute link.
This patch adds a second level of caching. When we do have to call
realpath, we cache its result for its parents path. We didn't replace
the existing caching, because it's fast (indexed) and saves us from
reading the line table for entries we've already seen.
For WebkitCore this results in a decrease of 11% in linking time: from
85.79 to 76.11 seconds (average over 3 runs).
Differential revision: https://reviews.llvm.org/D43511
llvm-svn: 325757
Diffstat (limited to 'clang/lib/Frontend/CompilerInvocation.cpp')
0 files changed, 0 insertions, 0 deletions