mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-08-09 11:25:55 +00:00
[Hexagon] [NFC] Renaming *packetStart to *packetBegin
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@223243 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -196,7 +196,7 @@ void HexagonAsmPrinter::EmitInstruction(const MachineInstr *MI) {
|
|||||||
assert((Size+IgnoreCount) == MI->getBundleSize() && "Corrupt Bundle!");
|
assert((Size+IgnoreCount) == MI->getBundleSize() && "Corrupt Bundle!");
|
||||||
for (unsigned Index = 0; Index < Size; Index++) {
|
for (unsigned Index = 0; Index < Size; Index++) {
|
||||||
HexagonMCInst MCI;
|
HexagonMCInst MCI;
|
||||||
MCI.setPacketStart(Index == 0);
|
MCI.setPacketBegin(Index == 0);
|
||||||
MCI.setPacketEnd(Index == (Size-1));
|
MCI.setPacketEnd(Index == (Size-1));
|
||||||
|
|
||||||
HexagonLowerToMC(BundleMIs[Index], MCI, *this);
|
HexagonLowerToMC(BundleMIs[Index], MCI, *this);
|
||||||
@@ -206,7 +206,7 @@ void HexagonAsmPrinter::EmitInstruction(const MachineInstr *MI) {
|
|||||||
else {
|
else {
|
||||||
HexagonMCInst MCI;
|
HexagonMCInst MCI;
|
||||||
if (MI->getOpcode() == Hexagon::ENDLOOP0) {
|
if (MI->getOpcode() == Hexagon::ENDLOOP0) {
|
||||||
MCI.setPacketStart(true);
|
MCI.setPacketBegin(true);
|
||||||
MCI.setPacketEnd(true);
|
MCI.setPacketEnd(true);
|
||||||
}
|
}
|
||||||
HexagonLowerToMC(MI, MCI, *this);
|
HexagonLowerToMC(MI, MCI, *this);
|
||||||
|
@@ -91,14 +91,14 @@ void HexagonInstPrinter::printInst(const HexagonMCInst *MI, raw_ostream &O,
|
|||||||
// Ending a harware loop is different from ending an regular packet.
|
// Ending a harware loop is different from ending an regular packet.
|
||||||
assert(MI->isPacketEnd() && "Loop-end must also end the packet");
|
assert(MI->isPacketEnd() && "Loop-end must also end the packet");
|
||||||
|
|
||||||
if (MI->isPacketStart()) {
|
if (MI->isPacketBegin()) {
|
||||||
// There must be a packet to end a loop.
|
// There must be a packet to end a loop.
|
||||||
// FIXME: when shuffling is always run, this shouldn't be needed.
|
// FIXME: when shuffling is always run, this shouldn't be needed.
|
||||||
HexagonMCInst Nop;
|
HexagonMCInst Nop;
|
||||||
StringRef NoAnnot;
|
StringRef NoAnnot;
|
||||||
|
|
||||||
Nop.setOpcode (Hexagon::A2_nop);
|
Nop.setOpcode (Hexagon::A2_nop);
|
||||||
Nop.setPacketStart (MI->isPacketStart());
|
Nop.setPacketBegin (MI->isPacketBegin());
|
||||||
printInst (&Nop, O, NoAnnot);
|
printInst (&Nop, O, NoAnnot);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -110,7 +110,7 @@ void HexagonInstPrinter::printInst(const HexagonMCInst *MI, raw_ostream &O,
|
|||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
// Prefix the insn opening the packet.
|
// Prefix the insn opening the packet.
|
||||||
if (MI->isPacketStart())
|
if (MI->isPacketBegin())
|
||||||
O << PacketPadding << startPacket << '\n';
|
O << PacketPadding << startPacket << '\n';
|
||||||
|
|
||||||
printInstruction(MI, O);
|
printInstruction(MI, O);
|
||||||
|
@@ -27,19 +27,19 @@ namespace llvm {
|
|||||||
const MCInstrDesc *MCID;
|
const MCInstrDesc *MCID;
|
||||||
|
|
||||||
// Packet start and end markers
|
// Packet start and end markers
|
||||||
unsigned packetStart: 1, packetEnd: 1;
|
unsigned packetBegin: 1, packetEnd: 1;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
explicit HexagonMCInst():
|
explicit HexagonMCInst():
|
||||||
MCInst(), MCID(nullptr), packetStart(0), packetEnd(0) {};
|
MCInst(), MCID(nullptr), packetBegin(0), packetEnd(0) {};
|
||||||
HexagonMCInst(const MCInstrDesc& mcid):
|
HexagonMCInst(const MCInstrDesc& mcid):
|
||||||
MCInst(), MCID(&mcid), packetStart(0), packetEnd(0) {};
|
MCInst(), MCID(&mcid), packetBegin(0), packetEnd(0) {};
|
||||||
|
|
||||||
bool isPacketStart() const { return (packetStart); };
|
bool isPacketBegin() const { return (packetBegin); };
|
||||||
bool isPacketEnd() const { return (packetEnd); };
|
bool isPacketEnd() const { return (packetEnd); };
|
||||||
void setPacketStart(bool Y) { packetStart = Y; };
|
void setPacketBegin(bool Y) { packetBegin = Y; };
|
||||||
void setPacketEnd(bool Y) { packetEnd = Y; };
|
void setPacketEnd(bool Y) { packetEnd = Y; };
|
||||||
void resetPacket() { setPacketStart(false); setPacketEnd(false); };
|
void resetPacket() { setPacketBegin(false); setPacketEnd(false); };
|
||||||
|
|
||||||
// Return the slots used by the insn.
|
// Return the slots used by the insn.
|
||||||
unsigned getUnits(const HexagonTargetMachine* TM) const;
|
unsigned getUnits(const HexagonTargetMachine* TM) const;
|
||||||
|
Reference in New Issue
Block a user