mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-09-30 22:18:46 +00:00
minor tidying.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100338 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -1336,6 +1336,13 @@ void AsmPrinter::EmitMachineConstantPoolValue(MachineConstantPoolValue *MCPV) {
|
|||||||
llvm_unreachable("Target does not support EmitMachineConstantPoolValue");
|
llvm_unreachable("Target does not support EmitMachineConstantPoolValue");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void AsmPrinter::printOffset(int64_t Offset, raw_ostream &OS) const {
|
||||||
|
if (Offset > 0)
|
||||||
|
OS << '+' << Offset;
|
||||||
|
else if (Offset < 0)
|
||||||
|
OS << Offset;
|
||||||
|
}
|
||||||
|
|
||||||
/// PrintSpecial - Print information related to the specified machine instr
|
/// PrintSpecial - Print information related to the specified machine instr
|
||||||
/// that is independent of the operand, and may be independent of the instr
|
/// that is independent of the operand, and may be independent of the instr
|
||||||
/// itself. This can be useful for portably encoding the comment character
|
/// itself. This can be useful for portably encoding the comment character
|
||||||
@@ -1373,8 +1380,7 @@ void AsmPrinter::PrintSpecial(const MachineInstr *MI, raw_ostream &OS,
|
|||||||
/// instruction's DebugLoc.
|
/// instruction's DebugLoc.
|
||||||
void AsmPrinter::processDebugLoc(const MachineInstr *MI,
|
void AsmPrinter::processDebugLoc(const MachineInstr *MI,
|
||||||
bool BeforePrintingInsn) {
|
bool BeforePrintingInsn) {
|
||||||
if (!MAI || !DW || !MAI->doesSupportDebugInformation()
|
if (!DW || !MAI->doesSupportDebugInformation() || !DW->ShouldEmitDwarfDebug())
|
||||||
|| !DW->ShouldEmitDwarfDebug())
|
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (!BeforePrintingInsn)
|
if (!BeforePrintingInsn)
|
||||||
@@ -1724,8 +1730,8 @@ static void PrintChildLoopComment(raw_ostream &OS, const MachineLoop *Loop,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/// PrintBasicBlockLoopComments - Pretty-print comments for basic blocks.
|
/// EmitBasicBlockLoopComments - Pretty-print comments for basic blocks.
|
||||||
static void PrintBasicBlockLoopComments(const MachineBasicBlock &MBB,
|
static void EmitBasicBlockLoopComments(const MachineBasicBlock &MBB,
|
||||||
const MachineLoopInfo *LI,
|
const MachineLoopInfo *LI,
|
||||||
const AsmPrinter &AP) {
|
const AsmPrinter &AP) {
|
||||||
// Add loop depth information
|
// Add loop depth information
|
||||||
@@ -1793,7 +1799,7 @@ void AsmPrinter::EmitBasicBlockStart(const MachineBasicBlock *MBB) const {
|
|||||||
if (BB->hasName())
|
if (BB->hasName())
|
||||||
OutStreamer.AddComment("%" + BB->getName());
|
OutStreamer.AddComment("%" + BB->getName());
|
||||||
|
|
||||||
PrintBasicBlockLoopComments(*MBB, LI, *this);
|
EmitBasicBlockLoopComments(*MBB, LI, *this);
|
||||||
|
|
||||||
// NOTE: Want this comment at start of line, don't emit with AddComment.
|
// NOTE: Want this comment at start of line, don't emit with AddComment.
|
||||||
OutStreamer.EmitRawText(Twine(MAI->getCommentString()) + " BB#" +
|
OutStreamer.EmitRawText(Twine(MAI->getCommentString()) + " BB#" +
|
||||||
@@ -1804,7 +1810,7 @@ void AsmPrinter::EmitBasicBlockStart(const MachineBasicBlock *MBB) const {
|
|||||||
if (const BasicBlock *BB = MBB->getBasicBlock())
|
if (const BasicBlock *BB = MBB->getBasicBlock())
|
||||||
if (BB->hasName())
|
if (BB->hasName())
|
||||||
OutStreamer.AddComment("%" + BB->getName());
|
OutStreamer.AddComment("%" + BB->getName());
|
||||||
PrintBasicBlockLoopComments(*MBB, LI, *this);
|
EmitBasicBlockLoopComments(*MBB, LI, *this);
|
||||||
}
|
}
|
||||||
|
|
||||||
OutStreamer.EmitLabel(MBB->getSymbol());
|
OutStreamer.EmitLabel(MBB->getSymbol());
|
||||||
@@ -1828,13 +1834,6 @@ void AsmPrinter::EmitVisibility(MCSymbol *Sym, unsigned Visibility) const {
|
|||||||
OutStreamer.EmitSymbolAttribute(Sym, Attr);
|
OutStreamer.EmitSymbolAttribute(Sym, Attr);
|
||||||
}
|
}
|
||||||
|
|
||||||
void AsmPrinter::printOffset(int64_t Offset, raw_ostream &OS) const {
|
|
||||||
if (Offset > 0)
|
|
||||||
OS << '+' << Offset;
|
|
||||||
else if (Offset < 0)
|
|
||||||
OS << Offset;
|
|
||||||
}
|
|
||||||
|
|
||||||
/// isBlockOnlyReachableByFallthough - Return true if the basic block has
|
/// isBlockOnlyReachableByFallthough - Return true if the basic block has
|
||||||
/// exactly one predecessor and the control transfer mechanism between
|
/// exactly one predecessor and the control transfer mechanism between
|
||||||
/// the predecessor and this block is a fall-through.
|
/// the predecessor and this block is a fall-through.
|
||||||
|
Reference in New Issue
Block a user