[PATCH] D85807: [Target] Cache the command line derived feature map in TargetOptions.
Nick Desaulniers via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Aug 12 10:27:01 PDT 2020
nickdesaulniers accepted this revision.
nickdesaulniers added a comment.
This revision is now accepted and ready to land.
LGTM; comparing the report at the bottom of https://reviews.llvm.org/D85257#2197114, repasted (before this patch):
+ 3.59% clang-12 [.] llvm::X86::getImpliedFeatures
- 3.36% clang-12 [.] llvm::StringMapImpl::LookupBucketFor
- 3.32% llvm::StringMapImpl::LookupBucketFor
- 1.24% llvm::StringMap<bool, llvm::MallocAllocator>::try_emplace<>
+ 1.24% clang::targets::X86TargetInfo::setFeatureEnabled
Elapsed (wall clock) time (h:mm:ss or m:ss): 0:53.39
(After this patch):
A profile of a full x86_64 build with this applied, none of the above appear in the profile. `clang::targets::X86TargetInfo::setFeatureEnabled`, does but near at the bottom with < 0.00%. So this shaves another ~5% off build times!
Elapsed (wall clock) time (h:mm:ss or m:ss): 0:50.98
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D85807/new/
https://reviews.llvm.org/D85807
More information about the cfe-commits
mailing list