Skip to content

Commit abb742a

Browse files
committed
address comment
1 parent 4d99a4b commit abb742a

File tree

1 file changed

+13
-13
lines changed

1 file changed

+13
-13
lines changed

llvm/lib/Target/PowerPC/PPCInstrInfo.cpp

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -5244,7 +5244,7 @@ void PPCInstrInfo::replaceInstrAfterElimExt32To64(const Register &Reg,
52445244
return;
52455245

52465246
unsigned Opcode = MI->getOpcode();
5247-
bool IsRelplaceIntr = false;
5247+
bool IsReplaceInstr = false;
52485248
switch (Opcode) {
52495249
case PPC::OR:
52505250
case PPC::OR8:
@@ -5264,7 +5264,7 @@ void PPCInstrInfo::replaceInstrAfterElimExt32To64(const Register &Reg,
52645264
}
52655265

52665266
if (Opcode == PPC::OR || Opcode == PPC::ISEL)
5267-
IsRelplaceIntr = true;
5267+
IsReplaceInstr = true;
52685268
else
52695269
return;
52705270
}
@@ -5299,7 +5299,7 @@ void PPCInstrInfo::replaceInstrAfterElimExt32To64(const Register &Reg,
52995299

53005300
if (Opcode == PPC::ORI || Opcode == PPC::XORI || Opcode == PPC::ORIS ||
53015301
Opcode == PPC::ORIS || Opcode == PPC::XORIS)
5302-
IsRelplaceIntr = true;
5302+
IsReplaceInstr = true;
53035303
else
53045304
return;
53055305
break;
@@ -5312,7 +5312,7 @@ void PPCInstrInfo::replaceInstrAfterElimExt32To64(const Register &Reg,
53125312
Register SrcReg2 = MI->getOperand(2).getReg();
53135313
replaceInstrAfterElimExt32To64(SrcReg2, MRI, BinOpDepth, LV);
53145314
if (Opcode == PPC::AND)
5315-
IsRelplaceIntr = true;
5315+
IsReplaceInstr = true;
53165316
else
53175317
return;
53185318
}
@@ -5326,7 +5326,7 @@ void PPCInstrInfo::replaceInstrAfterElimExt32To64(const Register &Reg,
53265326
MI->getMF()->getSubtarget<PPCSubtarget>().getInstrInfo();
53275327
if ((definedBySignExtendingOp(Reg, MRI) && !TII->isZExt32To64(Opcode) &&
53285328
!isOpZeroOfSubwordPreincLoad(Opcode)) ||
5329-
IsRelplaceIntr) {
5329+
IsReplaceInstr) {
53305330

53315331
const TargetRegisterClass *RC = MRI->getRegClass(Reg);
53325332
assert(RC != &PPC::G8RCRegClass && RC != &PPC::G8RC_and_G8RC_NOX0RegClass &&
@@ -5367,29 +5367,29 @@ void PPCInstrInfo::replaceInstrAfterElimExt32To64(const Register &Reg,
53675367
DenseMap<unsigned, Register> PromoteRegs;
53685368
DenseMap<unsigned, Register> ReCalRegs;
53695369
for (unsigned i = 1; i < MI->getNumOperands(); i++) {
5370-
MachineOperand &Oprand = MI->getOperand(i);
5371-
if (Oprand.isReg()) {
5372-
Register OprandReg = Oprand.getReg();
5373-
if (!OprandReg.isVirtual())
5370+
MachineOperand &Operand = MI->getOperand(i);
5371+
if (Operand.isReg()) {
5372+
Register OperandReg = Operand.getReg();
5373+
if (!OperandReg.isVirtual())
53745374
continue;
53755375

53765376
const TargetRegisterClass *RC =
53775377
TRI->getRegClass(MCID.operands()[i].RegClass);
5378-
const TargetRegisterClass *OrgRC = MRI->getRegClass(OprandReg);
5379-
if (RC != MRI->getRegClass(OprandReg) &&
5378+
const TargetRegisterClass *OrgRC = MRI->getRegClass(OperandReg);
5379+
if (RC != MRI->getRegClass(OperandReg) &&
53805380
(OrgRC == &PPC::GPRCRegClass ||
53815381
OrgRC == &PPC::GPRC_and_GPRC_NOR0RegClass)) {
53825382
Register TmpReg = MRI->createVirtualRegister(RC);
53835383
Register DstTmpReg = MRI->createVirtualRegister(RC);
53845384
BuildMI(*MBB, MI, DL, TII->get(PPC::IMPLICIT_DEF), TmpReg);
53855385
BuildMI(*MBB, MI, DL, TII->get(PPC::INSERT_SUBREG), DstTmpReg)
53865386
.addReg(TmpReg)
5387-
.addReg(OprandReg)
5387+
.addReg(OperandReg)
53885388
.addImm(PPC::sub_32);
53895389
PromoteRegs[i] = DstTmpReg;
53905390
ReCalRegs[i] = DstTmpReg;
53915391
} else {
5392-
ReCalRegs[i] = OprandReg;
5392+
ReCalRegs[i] = OperandReg;
53935393
}
53945394
}
53955395
}

0 commit comments

Comments
 (0)