[VPlan] Print result value for loads in VPWidenMemoryInst (NFC).

For loads, print the result value.
This commit is contained in:
Florian Hahn 2020-11-09 13:52:54 +00:00
parent 537829f2a7
commit f0d76275cb
No known key found for this signature in database
GPG Key ID: 61D7554B5CECDC0D
2 changed files with 8 additions and 3 deletions

View File

@ -928,8 +928,13 @@ void VPPredInstPHIRecipe::print(raw_ostream &O, const Twine &Indent,
void VPWidenMemoryInstructionRecipe::print(raw_ostream &O, const Twine &Indent,
VPSlotTracker &SlotTracker) const {
O << "\"WIDEN "
<< Instruction::getOpcodeName(getUnderlyingInstr()->getOpcode()) << " ";
O << "\"WIDEN ";
if (!isStore()) {
printAsOperand(O, SlotTracker);
O << " = ";
}
O << Instruction::getOpcodeName(getUnderlyingInstr()->getOpcode()) << " ";
printOperands(O, SlotTracker);
}

View File

@ -11,7 +11,7 @@ define void @print_call_and_memory(i64 %n, float* noalias %y, float* noalias %x)
; CHECK-NEXT: "for.body:\n" +
; CHECK-NEXT: "WIDEN-INDUCTION %iv = phi %iv.next, 0\l" +
; CHECK-NEXT: "CLONE %arrayidx = getelementptr %y, %iv\l" +
; CHECK-NEXT: "WIDEN load ir<%arrayidx>\l" +
; CHECK-NEXT: "WIDEN ir<%lv> = load ir<%arrayidx>\l" +
; CHECK-NEXT: "WIDEN-CALL ir<%call> = call @llvm.sqrt.f32(ir<%lv>)\l" +
; CHECK-NEXT: "CLONE %arrayidx2 = getelementptr %x, %iv\l" +
; CHECK-NEXT: "WIDEN store ir<%arrayidx2>, ir<%call>\l"