Skip to content

Commit c7b2124

Browse files
author
Colin LeMahieu
committed
[NFC] Fixing naming convention, lowercase start of function name.
llvm-svn: 260903
1 parent 98c8e07 commit c7b2124

File tree

6 files changed

+33
-33
lines changed

6 files changed

+33
-33
lines changed

llvm/lib/Target/Hexagon/AsmParser/HexagonAsmParser.cpp

+19-19
Original file line numberDiff line numberDiff line change
@@ -768,7 +768,7 @@ void HexagonAsmParser::canonicalizeImmediates(MCInst &MCI) {
768768
if (WarnSignedMismatch)
769769
Warning (MCI.getLoc(), "Signed/Unsigned mismatch");
770770
}
771-
NewInst.addOperand(MCOperand::createExpr(HexagonMCExpr::Create(
771+
NewInst.addOperand(MCOperand::createExpr(HexagonMCExpr::create(
772772
MCConstantExpr::create(Value, getContext()), getContext())));
773773
}
774774
else
@@ -919,7 +919,7 @@ bool HexagonAsmParser::ParseDirectiveSubsection(SMLoc L) {
919919
// end of the section. Only legacy hexagon-gcc created assembly code
920920
// used negative subsections.
921921
if ((Res < 0) && (Res > -8193))
922-
Subsection = HexagonMCExpr::Create(
922+
Subsection = HexagonMCExpr::create(
923923
MCConstantExpr::create(8192 + Res, getContext()), getContext());
924924

925925
getStreamer().SubSection(Subsection);
@@ -1339,7 +1339,7 @@ bool HexagonAsmParser::parseExpressionOrOperand(OperandVector &Operands) {
13391339
SMLoc Loc = Parser.getLexer().getLoc();
13401340
MCExpr const *Expr = nullptr;
13411341
bool Error = parseExpression(Expr);
1342-
Expr = HexagonMCExpr::Create(Expr, getContext());
1342+
Expr = HexagonMCExpr::create(Expr, getContext());
13431343
if (!Error)
13441344
Operands.push_back(HexagonOperand::CreateImm(Expr, Loc, Loc));
13451345
return Error;
@@ -1441,7 +1441,7 @@ bool HexagonAsmParser::parseInstruction(OperandVector &Operands) {
14411441
MCConstantExpr::create(0xffff, Context),
14421442
Context);
14431443
}
1444-
Expr = HexagonMCExpr::Create(Expr, Context);
1444+
Expr = HexagonMCExpr::create(Expr, Context);
14451445
HexagonMCInstrInfo::setMustNotExtend(*Expr, MustNotExtend);
14461446
std::unique_ptr<HexagonOperand> Operand =
14471447
HexagonOperand::CreateImm(Expr, ExprLoc, ExprLoc);
@@ -1563,7 +1563,7 @@ int HexagonAsmParser::processInstruction(MCInst &Inst,
15631563

15641564
case Hexagon::C2_cmpgei: {
15651565
MCOperand &MO = Inst.getOperand(2);
1566-
MO.setExpr(HexagonMCExpr::Create(MCBinaryExpr::createSub(
1566+
MO.setExpr(HexagonMCExpr::create(MCBinaryExpr::createSub(
15671567
MO.getExpr(), MCConstantExpr::create(1, Context), Context), Context));
15681568
Inst.setOpcode(Hexagon::C2_cmpgti);
15691569
break;
@@ -1585,7 +1585,7 @@ int HexagonAsmParser::processInstruction(MCInst &Inst,
15851585
TmpInst.addOperand(Rt);
15861586
Inst = TmpInst;
15871587
} else {
1588-
MO.setExpr(HexagonMCExpr::Create(MCBinaryExpr::createSub(
1588+
MO.setExpr(HexagonMCExpr::create(MCBinaryExpr::createSub(
15891589
MO.getExpr(), MCConstantExpr::create(1, Context), Context), Context));
15901590
Inst.setOpcode(Hexagon::C2_cmpgtui);
15911591
}
@@ -1782,7 +1782,7 @@ int HexagonAsmParser::processInstruction(MCInst &Inst,
17821782
int64_t Value;
17831783
int sVal = (MO.getExpr()->evaluateAsAbsolute(Value) && Value < 0) ? -1 : 0;
17841784
MCOperand imm(MCOperand::createExpr(
1785-
HexagonMCExpr::Create(MCConstantExpr::create(sVal, Context), Context)));
1785+
HexagonMCExpr::create(MCConstantExpr::create(sVal, Context), Context)));
17861786
Inst = makeCombineInst(Hexagon::A2_combineii, Rdd, imm, MO);
17871787
break;
17881788
}
@@ -1797,14 +1797,14 @@ int HexagonAsmParser::processInstruction(MCInst &Inst,
17971797
signed int s8 = (u64 >> 32) & 0xFFFFFFFF;
17981798
if (s8 < -128 || s8 > 127)
17991799
OutOfRange(IDLoc, s8, -128);
1800-
MCOperand imm(MCOperand::createExpr(HexagonMCExpr::Create(
1800+
MCOperand imm(MCOperand::createExpr(HexagonMCExpr::create(
18011801
MCConstantExpr::create(s8, Context), Context))); // upper 32
1802-
MCOperand imm2(MCOperand::createExpr(HexagonMCExpr::Create(
1802+
MCOperand imm2(MCOperand::createExpr(HexagonMCExpr::create(
18031803
MCConstantExpr::create(u64 & 0xFFFFFFFF, Context),
18041804
Context))); // lower 32
18051805
Inst = makeCombineInst(Hexagon::A4_combineii, Rdd, imm, imm2);
18061806
} else {
1807-
MCOperand imm(MCOperand::createExpr(HexagonMCExpr::Create(
1807+
MCOperand imm(MCOperand::createExpr(HexagonMCExpr::create(
18081808
MCConstantExpr::create(0, Context), Context))); // upper 32
18091809
Inst = makeCombineInst(Hexagon::A4_combineii, Rdd, imm, MO);
18101810
}
@@ -1853,7 +1853,7 @@ int HexagonAsmParser::processInstruction(MCInst &Inst,
18531853
MCOperand &Rs = Inst.getOperand(2);
18541854
MCOperand &Imm4 = Inst.getOperand(3);
18551855
MCOperand &Imm6 = Inst.getOperand(4);
1856-
Imm6.setExpr(HexagonMCExpr::Create(MCBinaryExpr::createSub(
1856+
Imm6.setExpr(HexagonMCExpr::create(MCBinaryExpr::createSub(
18571857
Imm6.getExpr(), MCConstantExpr::create(1, Context), Context), Context));
18581858
TmpInst.setOpcode(Hexagon::S2_tableidxh);
18591859
TmpInst.addOperand(Rx);
@@ -1872,7 +1872,7 @@ int HexagonAsmParser::processInstruction(MCInst &Inst,
18721872
MCOperand &Rs = Inst.getOperand(2);
18731873
MCOperand &Imm4 = Inst.getOperand(3);
18741874
MCOperand &Imm6 = Inst.getOperand(4);
1875-
Imm6.setExpr(HexagonMCExpr::Create(MCBinaryExpr::createSub(
1875+
Imm6.setExpr(HexagonMCExpr::create(MCBinaryExpr::createSub(
18761876
Imm6.getExpr(), MCConstantExpr::create(2, Context), Context), Context));
18771877
TmpInst.setOpcode(Hexagon::S2_tableidxw);
18781878
TmpInst.addOperand(Rx);
@@ -1891,7 +1891,7 @@ int HexagonAsmParser::processInstruction(MCInst &Inst,
18911891
MCOperand &Rs = Inst.getOperand(2);
18921892
MCOperand &Imm4 = Inst.getOperand(3);
18931893
MCOperand &Imm6 = Inst.getOperand(4);
1894-
Imm6.setExpr(HexagonMCExpr::Create(MCBinaryExpr::createSub(
1894+
Imm6.setExpr(HexagonMCExpr::create(MCBinaryExpr::createSub(
18951895
Imm6.getExpr(), MCConstantExpr::create(3, Context), Context), Context));
18961896
TmpInst.setOpcode(Hexagon::S2_tableidxd);
18971897
TmpInst.addOperand(Rx);
@@ -1918,7 +1918,7 @@ int HexagonAsmParser::processInstruction(MCInst &Inst,
19181918
(void)Absolute;
19191919
if (!MustExtend) {
19201920
if (Value < 0 && Value > -256) {
1921-
Imm.setExpr(HexagonMCExpr::Create(
1921+
Imm.setExpr(HexagonMCExpr::create(
19221922
MCConstantExpr::create(Value * -1, Context), Context));
19231923
TmpInst.setOpcode(Hexagon::M2_mpysin);
19241924
} else if (Value < 256 && Value >= 0)
@@ -1952,7 +1952,7 @@ int HexagonAsmParser::processInstruction(MCInst &Inst,
19521952
TmpInst.addOperand(Rd);
19531953
TmpInst.addOperand(Rs);
19541954
} else {
1955-
Imm.setExpr(HexagonMCExpr::Create(
1955+
Imm.setExpr(HexagonMCExpr::create(
19561956
MCBinaryExpr::createSub(Imm.getExpr(),
19571957
MCConstantExpr::create(1, Context), Context),
19581958
Context));
@@ -1990,7 +1990,7 @@ int HexagonAsmParser::processInstruction(MCInst &Inst,
19901990
TmpInst.addOperand(MCOperand::createReg(MatchRegisterName(Reg2)));
19911991
Inst = TmpInst;
19921992
} else {
1993-
Imm.setExpr(HexagonMCExpr::Create(
1993+
Imm.setExpr(HexagonMCExpr::create(
19941994
MCBinaryExpr::createSub(Imm.getExpr(),
19951995
MCConstantExpr::create(1, Context), Context),
19961996
Context));
@@ -2112,7 +2112,7 @@ int HexagonAsmParser::processInstruction(MCInst &Inst,
21122112
if (Value == 0)
21132113
Inst.setOpcode(Hexagon::S2_vsathub);
21142114
else {
2115-
Imm.setExpr(HexagonMCExpr::Create(
2115+
Imm.setExpr(HexagonMCExpr::create(
21162116
MCBinaryExpr::createSub(Imm.getExpr(),
21172117
MCConstantExpr::create(1, Context), Context),
21182118
Context));
@@ -2144,7 +2144,7 @@ int HexagonAsmParser::processInstruction(MCInst &Inst,
21442144
TmpInst.addOperand(MCOperand::createReg(MatchRegisterName(Reg2)));
21452145
Inst = TmpInst;
21462146
} else {
2147-
Imm.setExpr(HexagonMCExpr::Create(
2147+
Imm.setExpr(HexagonMCExpr::create(
21482148
MCBinaryExpr::createSub(Imm.getExpr(),
21492149
MCConstantExpr::create(1, Context), Context),
21502150
Context));
@@ -2160,7 +2160,7 @@ int HexagonAsmParser::processInstruction(MCInst &Inst,
21602160
TmpInst.setOpcode(Hexagon::A2_subri);
21612161
TmpInst.addOperand(Rd);
21622162
TmpInst.addOperand(MCOperand::createExpr(
2163-
HexagonMCExpr::Create(MCConstantExpr::create(-1, Context), Context)));
2163+
HexagonMCExpr::create(MCConstantExpr::create(-1, Context), Context)));
21642164
TmpInst.addOperand(Rs);
21652165
Inst = TmpInst;
21662166
break;

llvm/lib/Target/Hexagon/HexagonAsmPrinter.cpp

+7-7
Original file line numberDiff line numberDiff line change
@@ -297,7 +297,7 @@ void HexagonAsmPrinter::HexagonProcessInstruction(MCInst &Inst,
297297
MCOperand &Reg = MappedInst.getOperand(0);
298298
TmpInst.setOpcode(Hexagon::L2_loadrigp);
299299
TmpInst.addOperand(Reg);
300-
TmpInst.addOperand(MCOperand::createExpr(HexagonMCExpr::Create(
300+
TmpInst.addOperand(MCOperand::createExpr(HexagonMCExpr::create(
301301
MCSymbolRefExpr::create(Sym, OutContext), OutContext)));
302302
MappedInst = TmpInst;
303303
}
@@ -383,7 +383,7 @@ void HexagonAsmPrinter::HexagonProcessInstruction(MCInst &Inst,
383383
const MCExpr *One = MCConstantExpr::create(1, OutContext);
384384
const MCExpr *Sub = MCBinaryExpr::createSub(Expr, One, OutContext);
385385
TmpInst.addOperand(
386-
MCOperand::createExpr(HexagonMCExpr::Create(Sub, OutContext)));
386+
MCOperand::createExpr(HexagonMCExpr::create(Sub, OutContext)));
387387
MappedInst = TmpInst;
388388
return;
389389
}
@@ -418,7 +418,7 @@ void HexagonAsmPrinter::HexagonProcessInstruction(MCInst &Inst,
418418
const MCExpr *One = MCConstantExpr::create(1, OutContext);
419419
const MCExpr *Sub = MCBinaryExpr::createSub(Expr, One, OutContext);
420420
TmpInst.addOperand(
421-
MCOperand::createExpr(HexagonMCExpr::Create(Sub, OutContext)));
421+
MCOperand::createExpr(HexagonMCExpr::create(Sub, OutContext)));
422422
MappedInst = TmpInst;
423423
return;
424424
}
@@ -444,7 +444,7 @@ void HexagonAsmPrinter::HexagonProcessInstruction(MCInst &Inst,
444444
const MCExpr *One = MCConstantExpr::create(1, OutContext);
445445
const MCExpr *Sub = MCBinaryExpr::createSub(Expr, One, OutContext);
446446
TmpInst.addOperand(
447-
MCOperand::createExpr(HexagonMCExpr::Create(Sub, OutContext)));
447+
MCOperand::createExpr(HexagonMCExpr::create(Sub, OutContext)));
448448
MappedInst = TmpInst;
449449
return;
450450
}
@@ -476,10 +476,10 @@ void HexagonAsmPrinter::HexagonProcessInstruction(MCInst &Inst,
476476
bool Success = MO.getExpr()->evaluateAsAbsolute(Imm);
477477
if (Success && Imm < 0) {
478478
const MCExpr *MOne = MCConstantExpr::create(-1, OutContext);
479-
TmpInst.addOperand(MCOperand::createExpr(HexagonMCExpr::Create(MOne, OutContext)));
479+
TmpInst.addOperand(MCOperand::createExpr(HexagonMCExpr::create(MOne, OutContext)));
480480
} else {
481481
const MCExpr *Zero = MCConstantExpr::create(0, OutContext);
482-
TmpInst.addOperand(MCOperand::createExpr(HexagonMCExpr::Create(Zero, OutContext)));
482+
TmpInst.addOperand(MCOperand::createExpr(HexagonMCExpr::create(Zero, OutContext)));
483483
}
484484
TmpInst.addOperand(MO);
485485
MappedInst = TmpInst;
@@ -533,7 +533,7 @@ void HexagonAsmPrinter::HexagonProcessInstruction(MCInst &Inst,
533533
(void)Success;
534534
if (Value < 0 && Value > -256) {
535535
MappedInst.setOpcode(Hexagon::M2_mpysin);
536-
Imm.setExpr(HexagonMCExpr::Create(
536+
Imm.setExpr(HexagonMCExpr::create(
537537
MCUnaryExpr::createMinus(Expr, OutContext), OutContext));
538538
} else
539539
MappedInst.setOpcode(Hexagon::M2_mpysip);

llvm/lib/Target/Hexagon/HexagonMCInstLower.cpp

+4-4
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ static MCOperand GetSymbolRef(const MachineOperand &MO, const MCSymbol *Symbol,
6666
ME = MCBinaryExpr::createAdd(ME, MCConstantExpr::create(MO.getOffset(), MC),
6767
MC);
6868

69-
return MCOperand::createExpr(HexagonMCExpr::Create(ME, MC));
69+
return MCOperand::createExpr(HexagonMCExpr::create(ME, MC));
7070
}
7171

7272
// Create an MCInst from a MachineInstr
@@ -106,17 +106,17 @@ void llvm::HexagonLowerToMC(const MCInstrInfo &MCII, const MachineInstr *MI,
106106
// FP immediates are used only when setting GPRs, so they may be dealt
107107
// with like regular immediates from this point on.
108108
MCO = MCOperand::createExpr(
109-
HexagonMCExpr::Create(MCConstantExpr::create(*Val.bitcastToAPInt().getRawData(),
109+
HexagonMCExpr::create(MCConstantExpr::create(*Val.bitcastToAPInt().getRawData(),
110110
AP.OutContext), AP.OutContext));
111111
break;
112112
}
113113
case MachineOperand::MO_Immediate:
114114
MCO = MCOperand::createExpr(
115-
HexagonMCExpr::Create(MCConstantExpr::create(MO.getImm(), AP.OutContext), AP.OutContext));
115+
HexagonMCExpr::create(MCConstantExpr::create(MO.getImm(), AP.OutContext), AP.OutContext));
116116
break;
117117
case MachineOperand::MO_MachineBasicBlock:
118118
MCO = MCOperand::createExpr
119-
(HexagonMCExpr::Create(MCSymbolRefExpr::create(MO.getMBB()->getSymbol(),
119+
(HexagonMCExpr::create(MCSymbolRefExpr::create(MO.getMBB()->getSymbol(),
120120
AP.OutContext), AP.OutContext));
121121
break;
122122
case MachineOperand::MO_GlobalAddress:

llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCExpr.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ using namespace llvm;
1818

1919
#define DEBUG_TYPE "hexagon-mcexpr"
2020

21-
HexagonMCExpr *HexagonMCExpr::Create(MCExpr const *Expr, MCContext &Ctx) {
21+
HexagonMCExpr *HexagonMCExpr::create(MCExpr const *Expr, MCContext &Ctx) {
2222
return new (Ctx) HexagonMCExpr(Expr);
2323
}
2424

llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCExpr.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ namespace llvm {
1616
class MCInst;
1717
class HexagonMCExpr : public MCTargetExpr {
1818
public:
19-
static HexagonMCExpr *Create(MCExpr const *Expr, MCContext &Ctx);
19+
static HexagonMCExpr *create(MCExpr const *Expr, MCContext &Ctx);
2020
void printImpl(raw_ostream &OS, const MCAsmInfo *MAI) const override;
2121
bool evaluateAsRelocatableImpl(MCValue &Res, const MCAsmLayout *Layout,
2222
const MCFixup *Fixup) const override;

llvm/lib/Target/Hexagon/MCTargetDesc/HexagonMCInstrInfo.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ void HexagonMCInstrInfo::clampExtended(MCInstrInfo const &MCII,
9999
int64_t Value;
100100
if (exOp.getExpr()->evaluateAsAbsolute(Value)) {
101101
unsigned Shift = HexagonMCInstrInfo::getExtentAlignment(MCII, MCI);
102-
exOp.setExpr(HexagonMCExpr::Create(
102+
exOp.setExpr(HexagonMCExpr::create(
103103
MCConstantExpr::create((Value & 0x3f) << Shift, Context), Context));
104104
}
105105
}

0 commit comments

Comments
 (0)