mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-24 22:24:54 +00:00
Strengthen the "non-constant stride must dominate loop preheader" check.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@64703 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -89,6 +89,10 @@ namespace llvm {
|
||||
const SCEVHandle &Conc,
|
||||
ScalarEvolution &SE) const = 0;
|
||||
|
||||
/// dominates - Return true if elements that makes up this SCEV dominates
|
||||
/// the specified basic block.
|
||||
virtual bool dominates(BasicBlock *BB, DominatorTree *DT) const = 0;
|
||||
|
||||
/// print - Print out the internal representation of this scalar to the
|
||||
/// specified stream. This should really only be used for debugging
|
||||
/// purposes.
|
||||
@@ -124,6 +128,10 @@ namespace llvm {
|
||||
const SCEVHandle &Conc,
|
||||
ScalarEvolution &SE) const;
|
||||
|
||||
virtual bool dominates(BasicBlock *BB, DominatorTree *DT) const {
|
||||
return true;
|
||||
}
|
||||
|
||||
/// Methods for support type inquiry through isa, cast, and dyn_cast:
|
||||
static inline bool classof(const SCEVCouldNotCompute *S) { return true; }
|
||||
static bool classof(const SCEV *S);
|
||||
|
@@ -20,6 +20,7 @@ namespace llvm {
|
||||
class ConstantInt;
|
||||
class ConstantRange;
|
||||
class APInt;
|
||||
class DominatorTree;
|
||||
|
||||
enum SCEVTypes {
|
||||
// These should be ordered in terms of increasing complexity to make the
|
||||
@@ -58,6 +59,10 @@ namespace llvm {
|
||||
return this;
|
||||
}
|
||||
|
||||
bool dominates(BasicBlock *BB, DominatorTree *DT) const {
|
||||
return true;
|
||||
}
|
||||
|
||||
virtual void print(std::ostream &OS) const;
|
||||
void print(std::ostream *OS) const { if (OS) print(*OS); }
|
||||
|
||||
@@ -100,6 +105,8 @@ namespace llvm {
|
||||
return SE.getTruncateExpr(H, Ty);
|
||||
}
|
||||
|
||||
virtual bool dominates(BasicBlock *BB, DominatorTree *DT) const;
|
||||
|
||||
virtual void print(std::ostream &OS) const;
|
||||
void print(std::ostream *OS) const { if (OS) print(*OS); }
|
||||
|
||||
@@ -142,6 +149,8 @@ namespace llvm {
|
||||
return SE.getZeroExtendExpr(H, Ty);
|
||||
}
|
||||
|
||||
bool dominates(BasicBlock *BB, DominatorTree *DT) const;
|
||||
|
||||
virtual void print(std::ostream &OS) const;
|
||||
void print(std::ostream *OS) const { if (OS) print(*OS); }
|
||||
|
||||
@@ -184,6 +193,8 @@ namespace llvm {
|
||||
return SE.getSignExtendExpr(H, Ty);
|
||||
}
|
||||
|
||||
bool dominates(BasicBlock *BB, DominatorTree *DT) const;
|
||||
|
||||
virtual void print(std::ostream &OS) const;
|
||||
void print(std::ostream *OS) const { if (OS) print(*OS); }
|
||||
|
||||
@@ -250,6 +261,8 @@ namespace llvm {
|
||||
const SCEVHandle &Conc,
|
||||
ScalarEvolution &SE) const;
|
||||
|
||||
bool dominates(BasicBlock *BB, DominatorTree *DT) const;
|
||||
|
||||
virtual const char *getOperationStr() const = 0;
|
||||
|
||||
virtual const Type *getType() const { return getOperand(0)->getType(); }
|
||||
@@ -343,6 +356,7 @@ namespace llvm {
|
||||
return SE.getUDivExpr(L, R);
|
||||
}
|
||||
|
||||
bool dominates(BasicBlock *BB, DominatorTree *DT) const;
|
||||
|
||||
virtual const Type *getType() const;
|
||||
|
||||
@@ -437,6 +451,8 @@ namespace llvm {
|
||||
const SCEVHandle &Conc,
|
||||
ScalarEvolution &SE) const;
|
||||
|
||||
bool dominates(BasicBlock *BB, DominatorTree *DT) const;
|
||||
|
||||
virtual void print(std::ostream &OS) const;
|
||||
void print(std::ostream *OS) const { if (OS) print(*OS); }
|
||||
|
||||
@@ -518,6 +534,8 @@ namespace llvm {
|
||||
return this;
|
||||
}
|
||||
|
||||
bool dominates(BasicBlock *BB, DominatorTree *DT) const;
|
||||
|
||||
virtual const Type *getType() const;
|
||||
|
||||
virtual void print(std::ostream &OS) const;
|
||||
|
Reference in New Issue
Block a user