Skip to content

Commit 1fa0f30

Browse files
fixup! respond to review
1 parent fdd45f1 commit 1fa0f30

File tree

4 files changed

+10
-21
lines changed

4 files changed

+10
-21
lines changed

llvm/lib/Target/RISCV/GISel/RISCVInstructionSelector.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ class RISCVInstructionSelector : public InstructionSelector {
100100
return selectSHXADD_UWOp(Root, ShAmt);
101101
}
102102

103-
ComplexRendererFns selectVLOp(MachineOperand &Root) const;
103+
ComplexRendererFns renderVLOp(MachineOperand &Root) const;
104104

105105
// Custom renderers for tablegen
106106
void renderNegImm(MachineInstrBuilder &MIB, const MachineInstr &MI,
@@ -379,7 +379,7 @@ RISCVInstructionSelector::selectSHXADD_UWOp(MachineOperand &Root,
379379
}
380380

381381
InstructionSelector::ComplexRendererFns
382-
RISCVInstructionSelector::selectVLOp(MachineOperand &Root) const {
382+
RISCVInstructionSelector::renderVLOp(MachineOperand &Root) const {
383383
MachineRegisterInfo &MRI =
384384
Root.getParent()->getParent()->getParent()->getRegInfo();
385385
assert(Root.isReg() && "Expected operand to be a Register");

llvm/lib/Target/RISCV/RISCVGISel.td

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,9 +50,9 @@ def GIAddrRegImm :
5050
GIComplexOperandMatcher<s32, "selectAddrRegImm">,
5151
GIComplexPatternEquiv<AddrRegImm>;
5252

53-
def GIVLOpS32 : GIComplexOperandMatcher<s32, "selectVLOp">,
53+
def GIVLOpS32 : GIComplexOperandMatcher<s32, "renderVLOp">,
5454
GIComplexPatternEquiv<VLOp>;
55-
def GIVLOpS64 : GIComplexOperandMatcher<s64, "selectVLOp">,
55+
def GIVLOpS64 : GIComplexOperandMatcher<s64, "renderVLOp">,
5656
GIComplexPatternEquiv<VLOp>;
5757

5858
// Convert from i32 immediate to i64 target immediate to make SelectionDAG type

llvm/test/CodeGen/RISCV/GlobalISel/instruction-select/rvv/fail-select-vl-badnegative.mir

Lines changed: 0 additions & 17 deletions
This file was deleted.

llvm/test/CodeGen/RISCV/GlobalISel/instruction-select/rvv/select-vlop.mir renamed to llvm/test/CodeGen/RISCV/GlobalISel/instruction-select/rvv/render-vlop.mir

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,18 @@
22
# RUN: llc -mtriple=riscv32 -mattr=+v,+m -run-pass=instruction-select \
33
# RUN: -verify-machineinstrs %s -o - | FileCheck %s
44

5+
---
56
name: negative_vl
67
legalized: true
78
regBankSelected: true
89
tracksRegLiveness: true
910
body: |
1011
bb.1:
12+
; CHECK-LABEL: name: negative_vl
13+
; CHECK: [[ADDI:%[0-9]+]]:gprnox0 = ADDI $x0, -2
14+
; CHECK-NEXT: [[PseudoVMCLR_M_B1_:%[0-9]+]]:vr = PseudoVMCLR_M_B1 [[ADDI]], 0 /* e8 */
15+
; CHECK-NEXT: $v0 = COPY [[PseudoVMCLR_M_B1_]]
16+
; CHECK-NEXT: PseudoRET implicit $v0
1117
%0:gprb(s32) = G_CONSTANT i32 -2
1218
%1:vrb(<vscale x 1 x s1>) = G_VMCLR_VL %0(s32)
1319
$v0 = COPY %1(<vscale x 1 x s1>)

0 commit comments

Comments
 (0)