projects
/
platform
/
upstream
/
llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b5ff187
)
[SCEV] Update SCEVLoopGuardRewriter to hold reference to map. (NFC)
author
Florian Hahn
<flo@fhahn.com>
Sat, 13 Nov 2021 09:39:14 +0000
(09:39 +0000)
committer
Florian Hahn
<flo@fhahn.com>
Sat, 13 Nov 2021 09:39:14 +0000
(09:39 +0000)
SCEVLoopGuardRewriter doesn't need to copy the rewrite map. It can just
hold a const reference instead, to avoid an unnecessary copy.
llvm/lib/Analysis/ScalarEvolution.cpp
patch
|
blob
|
history
diff --git
a/llvm/lib/Analysis/ScalarEvolution.cpp
b/llvm/lib/Analysis/ScalarEvolution.cpp
index
d7effde
..
5bdbe40
100644
(file)
--- a/
llvm/lib/Analysis/ScalarEvolution.cpp
+++ b/
llvm/lib/Analysis/ScalarEvolution.cpp
@@
-13696,7
+13696,7
@@
ScalarEvolution::computeSymbolicMaxBackedgeTakenCount(const Loop *L) {
///
/// At the moment only rewriting SCEVUnknown is supported.
class SCEVLoopGuardRewriter : public SCEVRewriteVisitor<SCEVLoopGuardRewriter> {
-
DenseMap<const SCEV *, const SCEV *>
Map;
+
const DenseMap<const SCEV *, const SCEV *> &
Map;
public:
SCEVLoopGuardRewriter(ScalarEvolution &SE,