mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-01-31 20:51:52 +01:00
[SCEV] Cleanup SCEVInitRewriter. NFC.
Set default value for IgnoreOtherLoops of SCEVInitRewriter::rewrite to true to be consistent with SCEVPostIncRewriter which does not have this parameter but behaves as it would be true. This is follow up for rL326067. llvm-svn: 326174
This commit is contained in:
parent
e35270bbad
commit
13c7f86c5f
@ -4093,7 +4093,7 @@ namespace {
|
||||
class SCEVInitRewriter : public SCEVRewriteVisitor<SCEVInitRewriter> {
|
||||
public:
|
||||
static const SCEV *rewrite(const SCEV *S, const Loop *L, ScalarEvolution &SE,
|
||||
bool IgnoreOtherLoops = false) {
|
||||
bool IgnoreOtherLoops = true) {
|
||||
SCEVInitRewriter Rewriter(L, SE);
|
||||
const SCEV *Result = Rewriter.visit(S);
|
||||
if (Rewriter.hasSeenLoopVariantSCEVUnknown())
|
||||
@ -5020,7 +5020,7 @@ const SCEV *ScalarEvolution::createAddRecFromPHI(PHINode *PN) {
|
||||
// by one iteration:
|
||||
// PHI(f(0), f({1,+,1})) --> f({0,+,1})
|
||||
const SCEV *Shifted = SCEVShiftRewriter::rewrite(BEValue, L, *this);
|
||||
const SCEV *Start = SCEVInitRewriter::rewrite(Shifted, L, *this);
|
||||
const SCEV *Start = SCEVInitRewriter::rewrite(Shifted, L, *this, false);
|
||||
if (Shifted != getCouldNotCompute() &&
|
||||
Start != getCouldNotCompute()) {
|
||||
const SCEV *StartVal = getSCEV(StartValueV);
|
||||
|
Loading…
x
Reference in New Issue
Block a user