Skip to content

Commit 5a77b97

Browse files
fixup! use MRI from member variable
1 parent 4187c47 commit 5a77b97

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

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

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -380,10 +380,8 @@ RISCVInstructionSelector::selectSHXADD_UWOp(MachineOperand &Root,
380380

381381
InstructionSelector::ComplexRendererFns
382382
RISCVInstructionSelector::renderVLOp(MachineOperand &Root) const {
383-
MachineRegisterInfo &MRI =
384-
Root.getParent()->getParent()->getParent()->getRegInfo();
385383
assert(Root.isReg() && "Expected operand to be a Register");
386-
MachineInstr *RootDef = MRI.getVRegDef(Root.getReg());
384+
MachineInstr *RootDef = MRI->getVRegDef(Root.getReg());
387385

388386
if (RootDef->getOpcode() == TargetOpcode::G_CONSTANT) {
389387
auto C = RootDef->getOperand(1).getCImm();

0 commit comments

Comments
 (0)