forked from OSchip/llvm-project
parent
35878c4752
commit
e4c20da3e7
|
@ -176,11 +176,11 @@ IRAccess TempScopInfo::buildIRAccess(Instruction *Inst, Loop *L, Region *R) {
|
|||
const SCEV *Remainder = AF->delinearize(*SE, Subscripts, Sizes);
|
||||
int NSubs = Subscripts.size();
|
||||
|
||||
// Normalize the last dimension: integrate the size of the "scalar dimension"
|
||||
// and the remainder of the delinearization.
|
||||
Subscripts[NSubs-1] = SE->getMulExpr(Subscripts[NSubs-1],
|
||||
Sizes[NSubs-1]);
|
||||
Subscripts[NSubs-1] = SE->getAddExpr(Subscripts[NSubs-1], Remainder);
|
||||
// Normalize the last dimension: integrate the size of the "scalar
|
||||
// dimension" and the remainder of the delinearization.
|
||||
Subscripts[NSubs - 1] =
|
||||
SE->getMulExpr(Subscripts[NSubs - 1], Sizes[NSubs - 1]);
|
||||
Subscripts[NSubs - 1] = SE->getAddExpr(Subscripts[NSubs - 1], Remainder);
|
||||
|
||||
for (int i = 0; i < NSubs; ++i)
|
||||
if (!isAffineExpr(R, Subscripts[i], *SE, BasePointer->getValue())) {
|
||||
|
@ -195,8 +195,8 @@ IRAccess TempScopInfo::buildIRAccess(Instruction *Inst, Loop *L, Region *R) {
|
|||
IsAffine = isAffineExpr(R, AccessFunction, *SE, BasePointer->getValue());
|
||||
}
|
||||
|
||||
return IRAccess(Type, BasePointer->getValue(), AccessFunction, Size,
|
||||
IsAffine, Subscripts, Sizes);
|
||||
return IRAccess(Type, BasePointer->getValue(), AccessFunction, Size, IsAffine,
|
||||
Subscripts, Sizes);
|
||||
}
|
||||
|
||||
void TempScopInfo::buildAccessFunctions(Region &R, BasicBlock &BB) {
|
||||
|
|
Loading…
Reference in New Issue