llvm-project/llvm/lib/Transforms/ObjCARC
Michael Zolotukhin a3d8ef0f08 Improve caching scheme in ProvenanceAnalysis.
Summary:
ProvenanceAnalysis::related(A, B) currently memoizes its results, and on big
tests the cache grows too large, and we're spending most of the time
growing/looking through DenseMap.

This patch reduces the size of the cache by normalizing keys first: we do that
by calling GetUnderlyingObjCPtr on the input values. The results of
GetUnderlyingObjCPtr are also memoized in a separate cache.

The patch doesn't bring noticable changes to compile time on CTMark, however
significantly helps one of our internal tests.

Reviewers: gottesmm

Subscribers: hiraditya, llvm-commits

Differential Revision: https://reviews.llvm.org/D44270

llvm-svn: 327328
2018-03-12 20:36:25 +00:00
..
ARCRuntimeEntryPoints.h [Transforms] Fix some Clang-tidy modernize and Include What You Use warnings; other minor fixes (NFC). 2017-10-27 01:09:08 +00:00
BlotMapVector.h [Transforms] Fix some Clang-tidy modernize and Include What You Use warnings; other minor fixes (NFC). 2017-10-27 01:09:08 +00:00
CMakeLists.txt
DependencyAnalysis.cpp Sort the remaining #include lines in include/... and lib/.... 2017-06-06 11:49:48 +00:00
DependencyAnalysis.h
LLVMBuild.txt
ObjCARC.cpp Remove redundant includes from lib/Transforms. 2017-12-13 21:31:01 +00:00
ObjCARC.h [ObjCARC] Do not turn a call to @objc_autoreleaseReturnValue into a call 2018-01-19 23:51:13 +00:00
ObjCARCAPElim.cpp
ObjCARCContract.cpp [ObjCARC] Do not turn a call to @objc_autoreleaseReturnValue into a call 2018-01-19 23:51:13 +00:00
ObjCARCExpand.cpp
ObjCARCOpts.cpp [ObjCARC] Do not turn a call to @objc_autoreleaseReturnValue into a call 2018-01-19 23:51:13 +00:00
ProvenanceAnalysis.cpp Improve caching scheme in ProvenanceAnalysis. 2018-03-12 20:36:25 +00:00
ProvenanceAnalysis.h Improve caching scheme in ProvenanceAnalysis. 2018-03-12 20:36:25 +00:00
ProvenanceAnalysisEvaluator.cpp Sort the remaining #include lines in include/... and lib/.... 2017-06-06 11:49:48 +00:00
PtrState.cpp [Transforms] Fix some Clang-tidy modernize and Include What You Use warnings; other minor fixes (NFC). 2017-10-27 01:09:08 +00:00
PtrState.h [Transforms] Fix some Clang-tidy modernize and Include What You Use warnings; other minor fixes (NFC). 2017-10-27 01:09:08 +00:00