[PATCH] D71964: [LV] Use getMask() when printing recipe [NFCI]
Gil Rapaport via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sat Dec 28 23:11:38 PST 2019
This revision was automatically updated to reflect the committed changes.
Closed by commit rGd62bf16131e4: [LV] Use getMask() when printing recipe [NFCI] (authored by gilr).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D71964/new/
https://reviews.llvm.org/D71964
Files:
llvm/lib/Transforms/Vectorize/VPlan.cpp
llvm/lib/Transforms/Vectorize/VPlan.h
Index: llvm/lib/Transforms/Vectorize/VPlan.h
===================================================================
--- llvm/lib/Transforms/Vectorize/VPlan.h
+++ llvm/lib/Transforms/Vectorize/VPlan.h
@@ -1015,7 +1015,7 @@
/// Return the mask used by this recipe. Note that a full mask is represented
/// by a nullptr.
- VPValue *getMask() {
+ VPValue *getMask() const {
// Mask is the last operand.
return User ? User->getOperand(User->getNumOperands() - 1) : nullptr;
}
Index: llvm/lib/Transforms/Vectorize/VPlan.cpp
===================================================================
--- llvm/lib/Transforms/Vectorize/VPlan.cpp
+++ llvm/lib/Transforms/Vectorize/VPlan.cpp
@@ -735,9 +735,10 @@
void VPWidenMemoryInstructionRecipe::print(raw_ostream &O,
const Twine &Indent) const {
O << " +\n" << Indent << "\"WIDEN " << VPlanIngredient(&Instr);
- if (User) {
+ VPValue *Mask = getMask();
+ if (Mask) {
O << ", ";
- User->getOperand(0)->printAsOperand(O);
+ Mask->printAsOperand(O);
}
O << "\\l\"";
}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D71964.235498.patch
Type: text/x-patch
Size: 1091 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20191229/20637d2a/attachment.bin>
More information about the llvm-commits
mailing list