Skip to content

Commit ae7ce1c

Browse files
[CodeGen] Remove extraneous ArrayRef (NFC) (#90423)
We don't need to explicitly create an instance of ArrayRef here because getIndexedOffsetInType takes ArrayRef, and ArrayRef can be implicitly constructed from a C array.
1 parent 5e9937d commit ae7ce1c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

llvm/lib/CodeGen/InterleavedLoadCombinePass.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -890,7 +890,7 @@ struct VectorInfo {
890890
ConstantInt::get(Type::getInt32Ty(LI->getContext()), 0),
891891
ConstantInt::get(Type::getInt32Ty(LI->getContext()), i),
892892
};
893-
int64_t Ofs = DL.getIndexedOffsetInType(Result.VTy, ArrayRef(Idx, 2));
893+
int64_t Ofs = DL.getIndexedOffsetInType(Result.VTy, Idx);
894894
Result.EI[i] = ElementInfo(Offset + Ofs, i == 0 ? LI : nullptr);
895895
}
896896

0 commit comments

Comments
 (0)