This is a refactoring patch.
- Reduce the number of map searches by reusing the iterator.
- Add asserts to check that the entry is in the cache, as this is something BasicAA relies on to avoid infinite recursion.
Paths
| Differential D59151
[BasicAA] Reduce no of map searches. Assert map entry exists. [NFCI] ClosedPublic Authored by asbirlea on Mar 8 2019, 1:23 PM.
Details Summary This is a refactoring patch.
Diff Detail
Event Timeline
asbirlea marked 2 inline comments as done. Comment ActionsAddress comment.
asbirlea retitled this revision from [BasicAA] Reduce no of map seaches [NFCI]. to [BasicAA] Reduce no of map searches. Assert map entry exists. [NFCI].Mar 8 2019, 8:40 PM Comment Actions LGTM, really nice!
This revision is now accepted and ready to land.Mar 20 2019, 6:05 PM Closed by commit rL356644: [BasicAA] Reduce no of map seaches [NFCI]. (authored by asbirlea). · Explain WhyMar 20 2019, 10:01 PM This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 189914 lib/Analysis/BasicAliasAnalysis.cpp
|
While it's a bit awkward, I'd create a scope here because re-using CacheIt will be so tempting and is wrong.