From 05794498d95903d22e4402d005d1f03fab3bc78a Mon Sep 17 00:00:00 2001 From: Misha Brukman Date: Thu, 24 Jun 2004 17:31:42 +0000 Subject: [PATCH] * Order #includes * Use the DEBUG() guard for debug printouts git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14367 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Target/PowerPC/PPC32AsmPrinter.cpp | 12 +++++++----- lib/Target/PowerPC/PPCAsmPrinter.cpp | 12 +++++++----- lib/Target/PowerPC/PowerPCAsmPrinter.cpp | 12 +++++++----- 3 files changed, 21 insertions(+), 15 deletions(-) diff --git a/lib/Target/PowerPC/PPC32AsmPrinter.cpp b/lib/Target/PowerPC/PPC32AsmPrinter.cpp index 27ae6bde37a..37c415f6cc4 100644 --- a/lib/Target/PowerPC/PPC32AsmPrinter.cpp +++ b/lib/Target/PowerPC/PPC32AsmPrinter.cpp @@ -14,22 +14,23 @@ // //===----------------------------------------------------------------------===// -#include - +#define DEBUG_TYPE "asmprinter" #include "PowerPC.h" #include "PowerPCInstrInfo.h" #include "llvm/Constants.h" #include "llvm/DerivedTypes.h" #include "llvm/Module.h" #include "llvm/Assembly/Writer.h" -#include "llvm/CodeGen/MachineFunctionPass.h" #include "llvm/CodeGen/MachineConstantPool.h" +#include "llvm/CodeGen/MachineFunctionPass.h" #include "llvm/CodeGen/MachineInstr.h" #include "llvm/Target/TargetMachine.h" #include "llvm/Support/Mangler.h" +#include "Support/CommandLine.h" +#include "Support/Debug.h" #include "Support/Statistic.h" #include "Support/StringExtras.h" -#include "Support/CommandLine.h" +#include namespace llvm { @@ -526,7 +527,8 @@ void Printer::printMachineInstruction(const MachineInstr *MI) { } O << TII.getName(MI->getOpcode()) << " "; - std::cout << TII.getName(MI->getOpcode()) << " expects " << ArgCount << " args\n"; + DEBUG(std::cerr << TII.getName(MI->getOpcode()) << " expects " + << ArgCount << " args\n"); if(Opcode == PPC32::LOADLoAddr) { printOp(MI->getOperand(0)); diff --git a/lib/Target/PowerPC/PPCAsmPrinter.cpp b/lib/Target/PowerPC/PPCAsmPrinter.cpp index 27ae6bde37a..37c415f6cc4 100644 --- a/lib/Target/PowerPC/PPCAsmPrinter.cpp +++ b/lib/Target/PowerPC/PPCAsmPrinter.cpp @@ -14,22 +14,23 @@ // //===----------------------------------------------------------------------===// -#include - +#define DEBUG_TYPE "asmprinter" #include "PowerPC.h" #include "PowerPCInstrInfo.h" #include "llvm/Constants.h" #include "llvm/DerivedTypes.h" #include "llvm/Module.h" #include "llvm/Assembly/Writer.h" -#include "llvm/CodeGen/MachineFunctionPass.h" #include "llvm/CodeGen/MachineConstantPool.h" +#include "llvm/CodeGen/MachineFunctionPass.h" #include "llvm/CodeGen/MachineInstr.h" #include "llvm/Target/TargetMachine.h" #include "llvm/Support/Mangler.h" +#include "Support/CommandLine.h" +#include "Support/Debug.h" #include "Support/Statistic.h" #include "Support/StringExtras.h" -#include "Support/CommandLine.h" +#include namespace llvm { @@ -526,7 +527,8 @@ void Printer::printMachineInstruction(const MachineInstr *MI) { } O << TII.getName(MI->getOpcode()) << " "; - std::cout << TII.getName(MI->getOpcode()) << " expects " << ArgCount << " args\n"; + DEBUG(std::cerr << TII.getName(MI->getOpcode()) << " expects " + << ArgCount << " args\n"); if(Opcode == PPC32::LOADLoAddr) { printOp(MI->getOperand(0)); diff --git a/lib/Target/PowerPC/PowerPCAsmPrinter.cpp b/lib/Target/PowerPC/PowerPCAsmPrinter.cpp index 27ae6bde37a..37c415f6cc4 100644 --- a/lib/Target/PowerPC/PowerPCAsmPrinter.cpp +++ b/lib/Target/PowerPC/PowerPCAsmPrinter.cpp @@ -14,22 +14,23 @@ // //===----------------------------------------------------------------------===// -#include - +#define DEBUG_TYPE "asmprinter" #include "PowerPC.h" #include "PowerPCInstrInfo.h" #include "llvm/Constants.h" #include "llvm/DerivedTypes.h" #include "llvm/Module.h" #include "llvm/Assembly/Writer.h" -#include "llvm/CodeGen/MachineFunctionPass.h" #include "llvm/CodeGen/MachineConstantPool.h" +#include "llvm/CodeGen/MachineFunctionPass.h" #include "llvm/CodeGen/MachineInstr.h" #include "llvm/Target/TargetMachine.h" #include "llvm/Support/Mangler.h" +#include "Support/CommandLine.h" +#include "Support/Debug.h" #include "Support/Statistic.h" #include "Support/StringExtras.h" -#include "Support/CommandLine.h" +#include namespace llvm { @@ -526,7 +527,8 @@ void Printer::printMachineInstruction(const MachineInstr *MI) { } O << TII.getName(MI->getOpcode()) << " "; - std::cout << TII.getName(MI->getOpcode()) << " expects " << ArgCount << " args\n"; + DEBUG(std::cerr << TII.getName(MI->getOpcode()) << " expects " + << ArgCount << " args\n"); if(Opcode == PPC32::LOADLoAddr) { printOp(MI->getOperand(0)); -- 2.34.1