don't store a pointer to the loop in IVS

llvm-svn: 175304
This commit is contained in:
Sebastian Pop 2013-02-15 21:26:48 +00:00
parent 860e021fe6
commit f30d3b2d89
2 changed files with 3 additions and 3 deletions

View File

@ -276,7 +276,7 @@ class ScopStmt {
/// @brief The loop induction variables surrounding the statement.
///
/// This information is only needed for final code generation.
std::vector<std::pair<PHINode*, Loop*> > IVS;
std::vector<PHINode*> IVS;
std::vector<Loop*> NestLoops;
std::string BaseName;

View File

@ -593,7 +593,7 @@ ScopStmt::ScopStmt(Scop &parent, TempScop &tempScop, const Region &CurRegion,
for (unsigned i = 0, e = Nest.size(); i < e; ++i) {
PHINode *PN = Nest[i]->getCanonicalInductionVariable();
assert(PN && "Non canonical IV in Scop!");
IVS[i] = std::make_pair(PN, Nest[i]);
IVS[i] = PN;
NestLoops[i] = Nest[i];
}
@ -633,7 +633,7 @@ const char *ScopStmt::getBaseName() const { return BaseName.c_str(); }
const PHINode *
ScopStmt::getInductionVariableForDimension(unsigned Dimension) const {
return IVS[Dimension].first;
return IVS[Dimension];
}
const Loop *ScopStmt::getLoopForDimension(unsigned Dimension) const {