[polly] r308840 - Move MemoryAccess::NewAccessRelation to isl++
Tobias Grosser via llvm-commits
llvm-commits at lists.llvm.org
Sat Jul 22 21:08:38 PDT 2017
Author: grosser
Date: Sat Jul 22 21:08:38 2017
New Revision: 308840
URL: http://llvm.org/viewvc/llvm-project?rev=308840&view=rev
Log:
Move MemoryAccess::NewAccessRelation to isl++
We also move related accessor functions
Modified:
polly/trunk/include/polly/ScopInfo.h
polly/trunk/lib/Analysis/DependenceInfo.cpp
polly/trunk/lib/Analysis/ScopInfo.cpp
polly/trunk/lib/CodeGen/BlockGenerators.cpp
polly/trunk/lib/CodeGen/IslNodeBuilder.cpp
polly/trunk/lib/CodeGen/PPCGCodeGeneration.cpp
polly/trunk/lib/Exchange/JSONExporter.cpp
polly/trunk/lib/Transform/DeLICM.cpp
polly/trunk/lib/Transform/ScheduleOptimizer.cpp
polly/trunk/lib/Transform/Simplify.cpp
Modified: polly/trunk/include/polly/ScopInfo.h
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/include/polly/ScopInfo.h?rev=308840&r1=308839&r2=308840&view=diff
==============================================================================
--- polly/trunk/include/polly/ScopInfo.h (original)
+++ polly/trunk/include/polly/ScopInfo.h Sat Jul 22 21:08:38 2017
@@ -637,7 +637,7 @@ private:
isl::map AccessRelation;
/// Updated access relation read from JSCOP file.
- isl_map *NewAccessRelation;
+ isl::map NewAccessRelation;
/// Fortran arrays whose sizes are not statically known are stored in terms
/// of a descriptor struct. This maintains a raw pointer to the memory,
@@ -663,7 +663,7 @@ private:
isl::space getOriginalAccessRelationSpace() const;
/// Get the new access function imported or set by a pass
- __isl_give isl_map *getNewAccessRelation() const;
+ isl::map getNewAccessRelation() const;
/// Fold the memory access to consider parametric offsets
///
@@ -798,7 +798,7 @@ public:
}
/// Check if a new access relation was imported or set by a pass.
- bool hasNewAccessRelation() const { return NewAccessRelation; }
+ bool hasNewAccessRelation() const { return !NewAccessRelation.is_null(); }
/// Return the newest access relation of this access.
///
@@ -810,15 +810,13 @@ public:
/// As 2) is by construction "newer" than 1) we return the new access
/// relation if present.
///
- __isl_give isl_map *getLatestAccessRelation() const {
+ isl::map getLatestAccessRelation() const {
return hasNewAccessRelation() ? getNewAccessRelation()
- : getOriginalAccessRelation().release();
+ : getOriginalAccessRelation();
}
/// Old name of getLatestAccessRelation().
- __isl_give isl_map *getAccessRelation() const {
- return getLatestAccessRelation();
- }
+ isl::map getAccessRelation() const { return getLatestAccessRelation(); }
/// Get an isl map describing the memory address accessed.
///
Modified: polly/trunk/lib/Analysis/DependenceInfo.cpp
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/lib/Analysis/DependenceInfo.cpp?rev=308840&r1=308839&r2=308840&view=diff
==============================================================================
--- polly/trunk/lib/Analysis/DependenceInfo.cpp (original)
+++ polly/trunk/lib/Analysis/DependenceInfo.cpp Sat Jul 22 21:08:38 2017
@@ -134,7 +134,7 @@ static void collectInfo(Scop &S, isl_uni
for (ScopStmt &Stmt : S) {
for (MemoryAccess *MA : Stmt) {
isl_set *domcp = Stmt.getDomain();
- isl_map *accdom = MA->getAccessRelation();
+ isl_map *accdom = MA->getAccessRelation().release();
accdom = isl_map_intersect_domain(accdom, domcp);
@@ -625,7 +625,7 @@ void Dependences::calculateDependences(S
for (MemoryAccess *MA : Stmt) {
if (!MA->isReductionLike())
continue;
- isl_set *AccDomW = isl_map_wrap(MA->getAccessRelation());
+ isl_set *AccDomW = isl_map_wrap(MA->getAccessRelation().release());
isl_map *Identity =
isl_map_from_domain_and_range(isl_set_copy(AccDomW), AccDomW);
RED = isl_union_map_add_map(RED, Identity);
@@ -670,7 +670,7 @@ void Dependences::calculateDependences(S
if (!MA->isReductionLike())
continue;
- isl_set *AccDomW = isl_map_wrap(MA->getAccessRelation());
+ isl_set *AccDomW = isl_map_wrap(MA->getAccessRelation().release());
isl_union_map *AccRedDepU = isl_union_map_intersect_domain(
isl_union_map_copy(TC_RED), isl_union_set_from_set(AccDomW));
if (isl_union_map_is_empty(AccRedDepU)) {
Modified: polly/trunk/lib/Analysis/ScopInfo.cpp
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/lib/Analysis/ScopInfo.cpp?rev=308840&r1=308839&r2=308840&view=diff
==============================================================================
--- polly/trunk/lib/Analysis/ScopInfo.cpp (original)
+++ polly/trunk/lib/Analysis/ScopInfo.cpp Sat Jul 22 21:08:38 2017
@@ -640,10 +640,7 @@ static MemoryAccess::ReductionType getRe
}
}
-MemoryAccess::~MemoryAccess() {
- isl_set_free(InvalidDomain);
- isl_map_free(NewAccessRelation);
-}
+MemoryAccess::~MemoryAccess() { isl_set_free(InvalidDomain); }
const ScopArrayInfo *MemoryAccess::getOriginalScopArrayInfo() const {
isl_id *ArrayId = getArrayId();
@@ -668,11 +665,11 @@ __isl_give isl_id *MemoryAccess::getOrig
__isl_give isl_id *MemoryAccess::getLatestArrayId() const {
if (!hasNewAccessRelation())
return getOriginalArrayId();
- return isl_map_get_tuple_id(NewAccessRelation, isl_dim_out);
+ return NewAccessRelation.get_tuple_id(isl::dim::out).release();
}
__isl_give isl_map *MemoryAccess::getAddressFunction() const {
- return isl_map_lexmin(getAccessRelation());
+ return isl_map_lexmin(getAccessRelation().release());
}
__isl_give isl_pw_multi_aff *MemoryAccess::applyScheduleToAccessRelation(
@@ -699,16 +696,16 @@ isl::space MemoryAccess::getOriginalAcce
return AccessRelation.get_space();
}
-__isl_give isl_map *MemoryAccess::getNewAccessRelation() const {
- return isl_map_copy(NewAccessRelation);
+isl::map MemoryAccess::getNewAccessRelation() const {
+ return NewAccessRelation;
}
std::string MemoryAccess::getNewAccessRelationStr() const {
- return stringFromIslObj(NewAccessRelation);
+ return stringFromIslObj(NewAccessRelation.get());
}
std::string MemoryAccess::getAccessRelationStr() const {
- return isl::manage(getAccessRelation()).to_str();
+ return isl::manage(getAccessRelation().get()).to_str();
}
isl::basic_map MemoryAccess::createBasicAccessMap(ScopStmt *Statement) {
@@ -761,7 +758,7 @@ void MemoryAccess::assumeNoOutOfBound()
Outside = Outside.unite(DimOutside);
}
- Outside = Outside.apply(give(getAccessRelation()).reverse());
+ Outside = Outside.apply(getAccessRelation().reverse());
Outside = Outside.intersect(give(Statement->getDomain()));
Outside = Outside.params();
@@ -1020,9 +1017,9 @@ MemoryAccess::MemoryAccess(ScopStmt *Stm
__isl_take isl_map *AccRel)
: Kind(MemoryKind::Array), AccType(AccType), RedType(RT_NONE),
Statement(Stmt), InvalidDomain(nullptr), AccessInstruction(nullptr),
- IsAffine(true), AccessRelation(nullptr), NewAccessRelation(AccRel),
- FAD(nullptr) {
- auto *ArrayInfoId = isl_map_get_tuple_id(NewAccessRelation, isl_dim_out);
+ IsAffine(true), AccessRelation(nullptr),
+ NewAccessRelation(isl::manage(AccRel)), FAD(nullptr) {
+ auto *ArrayInfoId = NewAccessRelation.get_tuple_id(isl::dim::out).release();
auto *SAI = ScopArrayInfo::getFromId(ArrayInfoId);
Sizes.push_back(nullptr);
for (unsigned i = 1; i < SAI->getNumberOfDimensions(); i++)
@@ -1134,7 +1131,7 @@ static isl_map *getEqualAndLarger(__isl_
__isl_give isl_set *
MemoryAccess::getStride(__isl_take const isl_map *Schedule) const {
isl_map *S = const_cast<isl_map *>(Schedule);
- isl_map *AccessRelation = getAccessRelation();
+ isl_map *AccessRelation = getAccessRelation().release();
isl_space *Space = isl_space_range(isl_map_get_space(S));
isl_map *NextScatt = getEqualAndLarger(Space);
@@ -1232,14 +1229,13 @@ void MemoryAccess::setNewAccessRelation(
isl_id_free(NewArrayId);
#endif
- isl_map_free(NewAccessRelation);
NewAccess = isl_map_gist_domain(NewAccess, getStatement()->getDomain());
- NewAccessRelation = NewAccess;
+ NewAccessRelation = isl::manage(NewAccess);
}
bool MemoryAccess::isLatestPartialAccess() const {
isl::set StmtDom = give(getStatement()->getDomain());
- isl::set AccDom = give(isl_map_domain(getLatestAccessRelation()));
+ isl::set AccDom = getLatestAccessRelation().domain();
return isl_set_is_subset(StmtDom.keep(), AccDom.keep()) == isl_bool_false;
}
@@ -1857,8 +1853,8 @@ void ScopStmt::checkForReductions() {
// Then check each possible candidate pair.
for (const auto &CandidatePair : Candidates) {
bool Valid = true;
- isl_map *LoadAccs = CandidatePair.first->getAccessRelation();
- isl_map *StoreAccs = CandidatePair.second->getAccessRelation();
+ isl_map *LoadAccs = CandidatePair.first->getAccessRelation().release();
+ isl_map *StoreAccs = CandidatePair.second->getAccessRelation().release();
// Skip those with obviously unequal base addresses.
if (!isl_map_has_equal_space(LoadAccs, StoreAccs)) {
@@ -1876,8 +1872,8 @@ void ScopStmt::checkForReductions() {
if (MA == CandidatePair.first || MA == CandidatePair.second)
continue;
- isl_map *AccRel =
- isl_map_intersect_domain(MA->getAccessRelation(), getDomain());
+ isl_map *AccRel = isl_map_intersect_domain(
+ MA->getAccessRelation().release(), getDomain());
isl_set *Accs = isl_map_range(AccRel);
if (isl_set_has_equal_space(AllAccs, Accs)) {
@@ -2589,7 +2585,7 @@ static bool calculateMinMaxAccess(Scop::
isl::union_map Accesses = isl::union_map::empty(give(S.getParamSpace()));
for (MemoryAccess *MA : AliasGroup)
- Accesses = Accesses.add_map(give(MA->getAccessRelation()));
+ Accesses = Accesses.add_map(give(MA->getAccessRelation().release()));
Accesses = Accesses.intersect_domain(Domains);
isl::union_set Locations = Accesses.range();
@@ -3672,7 +3668,7 @@ void Scop::foldSizeConstantsToRight() {
for (auto &Access : AccessFunctions)
if (Access->getScopArrayInfo() == Array)
Access->setAccessRelation(isl_map_apply_range(
- Access->getAccessRelation(), isl_map_copy(Transform)));
+ Access->getAccessRelation().release(), isl_map_copy(Transform)));
isl_map_free(Transform);
@@ -3987,8 +3983,8 @@ void Scop::addInvariantLoads(ScopStmt &S
if (!MAs.empty()) {
auto *LastMA = MAs.front();
- auto *AR = isl_map_range(MA->getAccessRelation());
- auto *LastAR = isl_map_range(LastMA->getAccessRelation());
+ auto *AR = isl_map_range(MA->getAccessRelation().release());
+ auto *LastAR = isl_map_range(LastMA->getAccessRelation().release());
bool SameAR = isl_set_is_equal(AR, LastAR);
isl_set_free(AR);
isl_set_free(LastAR);
@@ -4080,7 +4076,7 @@ isl::set Scop::getNonHoistableCtx(Memory
if (hasNonHoistableBasePtrInScop(Access, Writes))
return nullptr;
- isl::map AccessRelation = give(Access->getAccessRelation());
+ isl::map AccessRelation = give(Access->getAccessRelation().release());
assert(!AccessRelation.is_empty());
if (AccessRelation.involves_dims(isl::dim::in, 0, Stmt.getNumIterators()))
@@ -4187,7 +4183,7 @@ static void replaceBasePtrArrays(Scop *S
continue;
isl_id *Id = New->getBasePtrId().release();
- isl_map *Map = Access->getAccessRelation();
+ isl_map *Map = Access->getAccessRelation().release();
Map = isl_map_set_tuple_id(Map, isl_dim_out, Id);
Access->setAccessRelation(Map);
}
@@ -4704,7 +4700,7 @@ Scop::getAccessesOfType(std::function<bo
continue;
isl_set *Domain = Stmt.getDomain();
- isl_map *AccessDomain = MA->getAccessRelation();
+ isl_map *AccessDomain = MA->getAccessRelation().release();
AccessDomain = isl_map_intersect_domain(AccessDomain, Domain);
Accesses = isl_union_map_add_map(Accesses, AccessDomain);
}
Modified: polly/trunk/lib/CodeGen/BlockGenerators.cpp
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/lib/CodeGen/BlockGenerators.cpp?rev=308840&r1=308839&r2=308840&view=diff
==============================================================================
--- polly/trunk/lib/CodeGen/BlockGenerators.cpp (original)
+++ polly/trunk/lib/CodeGen/BlockGenerators.cpp Sat Jul 22 21:08:38 2017
@@ -319,7 +319,7 @@ void BlockGenerator::generateArrayStore(
ValueMapT &BBMap, LoopToScevMapT <S,
isl_id_to_ast_expr *NewAccesses) {
MemoryAccess &MA = Stmt.getArrayAccessFor(Store);
- isl::set AccDom = give(isl_map_domain(MA.getAccessRelation()));
+ isl::set AccDom = MA.getAccessRelation().domain();
std::string Subject = MA.getId().get_name();
generateConditionalExecution(Stmt, AccDom, Subject.c_str(), [&, this]() {
@@ -545,7 +545,7 @@ void BlockGenerator::generateScalarLoads
#ifndef NDEBUG
auto *StmtDom = Stmt.getDomain();
- auto *AccDom = isl_map_domain(MA->getAccessRelation());
+ auto *AccDom = isl_map_domain(MA->getAccessRelation().release());
assert(isl_set_is_subset(StmtDom, AccDom) &&
"Scalar must be loaded in all statement instances");
isl_set_free(StmtDom);
@@ -645,7 +645,7 @@ void BlockGenerator::generateScalarStore
if (MA->isOriginalArrayKind() || MA->isRead())
continue;
- isl::set AccDom = give(isl_map_domain(MA->getAccessRelation()));
+ isl::set AccDom = MA->getAccessRelation().domain();
std::string Subject = MA->getId().get_name();
generateConditionalExecution(
@@ -1570,7 +1570,7 @@ void RegionGenerator::generateScalarStor
if (MA->isOriginalArrayKind() || MA->isRead())
continue;
- isl::set AccDom = give(isl_map_domain(MA->getAccessRelation()));
+ isl::set AccDom = MA->getAccessRelation().domain();
std::string Subject = MA->getId().get_name();
generateConditionalExecution(
Stmt, AccDom, Subject.c_str(), [&, this, MA]() {
Modified: polly/trunk/lib/CodeGen/IslNodeBuilder.cpp
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/lib/CodeGen/IslNodeBuilder.cpp?rev=308840&r1=308839&r2=308840&view=diff
==============================================================================
--- polly/trunk/lib/CodeGen/IslNodeBuilder.cpp (original)
+++ polly/trunk/lib/CodeGen/IslNodeBuilder.cpp Sat Jul 22 21:08:38 2017
@@ -806,7 +806,7 @@ IslNodeBuilder::createNewAccesses(ScopSt
auto Dom = Stmt->getDomain();
auto SchedDom = isl_set_from_union_set(
isl_union_map_domain(isl_union_map_copy(Schedule)));
- auto AccDom = isl_map_domain(MA->getAccessRelation());
+ auto AccDom = isl_map_domain(MA->getAccessRelation().release());
Dom = isl_set_intersect_params(Dom, Stmt->getParent()->getContext());
SchedDom =
isl_set_intersect_params(SchedDom, Stmt->getParent()->getContext());
Modified: polly/trunk/lib/CodeGen/PPCGCodeGeneration.cpp
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/lib/CodeGen/PPCGCodeGeneration.cpp?rev=308840&r1=308839&r2=308840&view=diff
==============================================================================
--- polly/trunk/lib/CodeGen/PPCGCodeGeneration.cpp (original)
+++ polly/trunk/lib/CodeGen/PPCGCodeGeneration.cpp Sat Jul 22 21:08:38 2017
@@ -2363,7 +2363,7 @@ public:
for (auto &Stmt : *S)
for (auto &Acc : Stmt)
if (Acc->getType() == AccessTy) {
- isl_map *Relation = Acc->getAccessRelation();
+ isl_map *Relation = Acc->getAccessRelation().release();
Relation = isl_map_intersect_domain(Relation, Stmt.getDomain());
isl_space *Space = isl_map_get_space(Relation);
@@ -2507,14 +2507,14 @@ public:
auto Access = isl_alloc_type(S->getIslCtx(), struct gpu_stmt_access);
Access->read = Acc->isRead();
Access->write = Acc->isWrite();
- Access->access = Acc->getAccessRelation();
+ Access->access = Acc->getAccessRelation().release();
isl_space *Space = isl_map_get_space(Access->access);
Space = isl_space_range(Space);
Space = isl_space_from_range(Space);
Space = isl_space_set_tuple_id(Space, isl_dim_in, Acc->getId().release());
isl_map *Universe = isl_map_universe(Space);
Access->tagged_access =
- isl_map_domain_product(Acc->getAccessRelation(), Universe);
+ isl_map_domain_product(Acc->getAccessRelation().release(), Universe);
Access->exact_write = !Acc->isMayWrite();
Access->ref_id = Acc->getId().release();
Access->next = Accesses;
Modified: polly/trunk/lib/Exchange/JSONExporter.cpp
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/lib/Exchange/JSONExporter.cpp?rev=308840&r1=308839&r2=308840&view=diff
==============================================================================
--- polly/trunk/lib/Exchange/JSONExporter.cpp (original)
+++ polly/trunk/lib/Exchange/JSONExporter.cpp Sat Jul 22 21:08:38 2017
@@ -459,7 +459,7 @@ bool JSONImporter::importAccesses(Scop &
errs() << "The access was not parsed successfully by ISL.\n";
return false;
}
- isl_map *CurrentAccessMap = MA->getAccessRelation();
+ isl_map *CurrentAccessMap = MA->getAccessRelation().release();
// Check if the number of parameter change
if (isl_map_dim(NewAccessMap, isl_dim_param) !=
Modified: polly/trunk/lib/Transform/DeLICM.cpp
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/lib/Transform/DeLICM.cpp?rev=308840&r1=308839&r2=308840&view=diff
==============================================================================
--- polly/trunk/lib/Transform/DeLICM.cpp (original)
+++ polly/trunk/lib/Transform/DeLICM.cpp Sat Jul 22 21:08:38 2017
@@ -1034,7 +1034,7 @@ protected:
/// The domain of the result is as narrow as possible.
isl::map getAccessRelationFor(MemoryAccess *MA) const {
auto Domain = getDomainFor(MA);
- auto AccRel = give(MA->getLatestAccessRelation());
+ auto AccRel = MA->getLatestAccessRelation();
return give(isl_map_intersect_domain(AccRel.take(), Domain.take()));
}
Modified: polly/trunk/lib/Transform/ScheduleOptimizer.cpp
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/lib/Transform/ScheduleOptimizer.cpp?rev=308840&r1=308839&r2=308840&view=diff
==============================================================================
--- polly/trunk/lib/Transform/ScheduleOptimizer.cpp (original)
+++ polly/trunk/lib/Transform/ScheduleOptimizer.cpp Sat Jul 22 21:08:38 2017
@@ -690,7 +690,7 @@ static bool isMatMulNonScalarReadAccess(
MatMulInfoTy &MMI) {
if (!MemAccess->isLatestArrayKind() || !MemAccess->isRead())
return false;
- isl_map *AccMap = MemAccess->getLatestAccessRelation();
+ isl_map *AccMap = MemAccess->getLatestAccessRelation().release();
if (isMatMulOperandAcc(AccMap, MMI.i, MMI.j) && !MMI.ReadFromC &&
isl_map_n_basic_map(AccMap) == 1) {
MMI.ReadFromC = MemAccess;
@@ -839,7 +839,7 @@ static bool containsMatrMult(__isl_keep
continue;
if (!MemAccessPtr->isWrite())
return false;
- auto *AccMap = MemAccessPtr->getLatestAccessRelation();
+ auto *AccMap = MemAccessPtr->getLatestAccessRelation().release();
if (isl_map_n_basic_map(AccMap) != 1 ||
!isMatMulOperandAcc(AccMap, MMI.i, MMI.j)) {
isl_map_free(AccMap);
@@ -1133,7 +1133,7 @@ static __isl_give isl_schedule_node *opt
{FirstDimSize, SecondDimSize, ThirdDimSize});
AccRel =
isl_map_set_tuple_id(AccRel, isl_dim_out, SAI->getBasePtrId().release());
- auto *OldAcc = MMI.B->getLatestAccessRelation();
+ auto *OldAcc = MMI.B->getLatestAccessRelation().release();
MMI.B->setNewAccessRelation(AccRel);
auto *ExtMap =
isl_map_project_out(isl_map_copy(MapOldIndVar), isl_dim_out, 2,
@@ -1146,7 +1146,7 @@ static __isl_give isl_schedule_node *opt
// originating statement is executed.
auto *DomainId = isl_set_get_tuple_id(Domain);
auto *NewStmt = Stmt->getParent()->addScopStmt(
- OldAcc, MMI.B->getLatestAccessRelation(), isl_set_copy(Domain));
+ OldAcc, MMI.B->getLatestAccessRelation().release(), isl_set_copy(Domain));
ExtMap = isl_map_set_tuple_id(ExtMap, isl_dim_out, isl_id_copy(DomainId));
ExtMap = isl_map_intersect_range(ExtMap, isl_set_copy(Domain));
ExtMap = isl_map_set_tuple_id(ExtMap, isl_dim_out, NewStmt->getDomainId());
@@ -1163,14 +1163,14 @@ static __isl_give isl_schedule_node *opt
{FirstDimSize, SecondDimSize, ThirdDimSize});
AccRel =
isl_map_set_tuple_id(AccRel, isl_dim_out, SAI->getBasePtrId().release());
- OldAcc = MMI.A->getLatestAccessRelation();
+ OldAcc = MMI.A->getLatestAccessRelation().release();
MMI.A->setNewAccessRelation(AccRel);
ExtMap = isl_map_project_out(MapOldIndVar, isl_dim_out, 3,
isl_map_dim(MapOldIndVar, isl_dim_out) - 3);
ExtMap = isl_map_reverse(ExtMap);
ExtMap = isl_map_fix_si(ExtMap, isl_dim_out, MMI.j, 0);
NewStmt = Stmt->getParent()->addScopStmt(
- OldAcc, MMI.A->getLatestAccessRelation(), isl_set_copy(Domain));
+ OldAcc, MMI.A->getLatestAccessRelation().release(), isl_set_copy(Domain));
// Restrict the domains of the copy statements to only execute when also its
// originating statement is executed.
Modified: polly/trunk/lib/Transform/Simplify.cpp
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/lib/Transform/Simplify.cpp?rev=308840&r1=308839&r2=308840&view=diff
==============================================================================
--- polly/trunk/lib/Transform/Simplify.cpp (original)
+++ polly/trunk/lib/Transform/Simplify.cpp Sat Jul 22 21:08:38 2017
@@ -170,7 +170,7 @@ private:
if (!Acc->isWrite())
continue;
- auto AccRel = give(Acc->getAccessRelation());
+ isl::map AccRel = Acc->getAccessRelation();
auto AccRelSpace = AccRel.get_space();
// Spaces being different means that they access different arrays.
@@ -211,7 +211,7 @@ private:
if (Stmt.isRegionStmt() && isExplicitAccess(MA))
break;
- auto AccRel = give(MA->getAccessRelation());
+ auto AccRel = MA->getAccessRelation();
AccRel = AccRel.intersect_domain(Domain);
AccRel = AccRel.intersect_params(give(S->getContext()));
@@ -265,10 +265,10 @@ private:
if (!RA->isLatestArrayKind())
continue;
- auto WARel = give(WA->getLatestAccessRelation());
+ auto WARel = WA->getLatestAccessRelation();
WARel = WARel.intersect_domain(give(WA->getStatement()->getDomain()));
WARel = WARel.intersect_params(give(S->getContext()));
- auto RARel = give(RA->getLatestAccessRelation());
+ auto RARel = RA->getLatestAccessRelation();
RARel = RARel.intersect_domain(give(RA->getStatement()->getDomain()));
RARel = RARel.intersect_params(give(S->getContext()));
@@ -297,7 +297,7 @@ private:
for (auto *WA : StoresToRemove) {
auto Stmt = WA->getStatement();
- auto AccRel = give(WA->getAccessRelation());
+ auto AccRel = WA->getAccessRelation();
auto AccVal = WA->getAccessValue();
DEBUG(dbgs() << "Cleanup of " << WA << ":\n");
More information about the llvm-commits
mailing list