[PATCH] D83459: Correctly update return status for MVEGatherScatterLowering
serge via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Jul 9 00:48:13 PDT 2020
serge-sans-paille created this revision.
serge-sans-paille added reviewers: anwel, foad, jdoerfert.
Herald added subscribers: llvm-commits, dmgreen, hiraditya.
Herald added a project: LLVM.
Correctly reflect change in the return status.
Patch needed to land https://reviews.llvm.org/D80916
https://reviews.llvm.org/D83459
Files:
llvm/lib/Target/ARM/MVEGatherScatterLowering.cpp
Index: llvm/lib/Target/ARM/MVEGatherScatterLowering.cpp
===================================================================
--- llvm/lib/Target/ARM/MVEGatherScatterLowering.cpp
+++ llvm/lib/Target/ARM/MVEGatherScatterLowering.cpp
@@ -990,26 +990,27 @@
SmallVector<IntrinsicInst *, 4> Gathers;
SmallVector<IntrinsicInst *, 4> Scatters;
+ bool Changed = false;
+
for (BasicBlock &BB : F) {
for (Instruction &I : BB) {
IntrinsicInst *II = dyn_cast<IntrinsicInst>(&I);
if (II && II->getIntrinsicID() == Intrinsic::masked_gather) {
Gathers.push_back(II);
if (isa<GetElementPtrInst>(II->getArgOperand(0)))
- optimiseOffsets(
+ Changed |= optimiseOffsets(
cast<Instruction>(II->getArgOperand(0))->getOperand(1),
II->getParent(), LI);
} else if (II && II->getIntrinsicID() == Intrinsic::masked_scatter) {
Scatters.push_back(II);
if (isa<GetElementPtrInst>(II->getArgOperand(1)))
- optimiseOffsets(
+ Changed |= optimiseOffsets(
cast<Instruction>(II->getArgOperand(1))->getOperand(1),
II->getParent(), LI);
}
}
}
- bool Changed = false;
for (unsigned i = 0; i < Gathers.size(); i++) {
IntrinsicInst *I = Gathers[i];
Value *L = lowerGather(I);
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D83459.276649.patch
Type: text/x-patch
Size: 1335 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200709/2c799b69/attachment.bin>
More information about the llvm-commits
mailing list