From: Misha Brukman Date: Fri, 6 Jun 2003 00:27:02 +0000 (+0000) Subject: All debug print statements are now output with the DEBUG() guard to make X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=f4ef4c881f851ae019f9f48d5473f9f1586d1dbc;p=oota-llvm.git All debug print statements are now output with the DEBUG() guard to make output clean so that tests can automatically diff the output. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6643 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/support/tools/TableGen/CodeEmitterGen.cpp b/support/tools/TableGen/CodeEmitterGen.cpp index cd259ec5d7c..293d1ae5684 100644 --- a/support/tools/TableGen/CodeEmitterGen.cpp +++ b/support/tools/TableGen/CodeEmitterGen.cpp @@ -21,14 +21,14 @@ void CodeEmitterGen::createEmitter(std::ostream &o) { o << "unsigned " << ClassName << "getBinaryCodeForInstr(MachineInstr &MI) {\n" << " unsigned Value = 0;\n" - << " std::cerr << MI;\n" + << " DEBUG(std::cerr << MI);\n" << " switch (MI.getOpcode()) {\n"; for (std::vector::iterator I = Insts.begin(), E = Insts.end(); I != E; ++I) { Record *R = *I; o << " case " << Namespace << R->getName() << ": {\n" - << " std::cerr << \"Emitting " << R->getName() << "\\n\";\n"; + << " DEBUG(std::cerr << \"Emitting " << R->getName() << "\\n\");\n"; const RecordVal *InstVal = R->getValue("Inst"); Init *InitVal = InstVal->getValue(); @@ -115,7 +115,7 @@ void CodeEmitterGen::createEmitter(std::ostream &o) { << " }\n"; } o << " default:\n" - << " std::cerr << \"Not supported instr: \" << MI << \"\\n\";\n" + << " DEBUG(std::cerr << \"Not supported instr: \" << MI << \"\\n\");\n" << " abort();\n" << " }\n" << " return Value;\n" diff --git a/utils/TableGen/CodeEmitterGen.cpp b/utils/TableGen/CodeEmitterGen.cpp index cd259ec5d7c..293d1ae5684 100644 --- a/utils/TableGen/CodeEmitterGen.cpp +++ b/utils/TableGen/CodeEmitterGen.cpp @@ -21,14 +21,14 @@ void CodeEmitterGen::createEmitter(std::ostream &o) { o << "unsigned " << ClassName << "getBinaryCodeForInstr(MachineInstr &MI) {\n" << " unsigned Value = 0;\n" - << " std::cerr << MI;\n" + << " DEBUG(std::cerr << MI);\n" << " switch (MI.getOpcode()) {\n"; for (std::vector::iterator I = Insts.begin(), E = Insts.end(); I != E; ++I) { Record *R = *I; o << " case " << Namespace << R->getName() << ": {\n" - << " std::cerr << \"Emitting " << R->getName() << "\\n\";\n"; + << " DEBUG(std::cerr << \"Emitting " << R->getName() << "\\n\");\n"; const RecordVal *InstVal = R->getValue("Inst"); Init *InitVal = InstVal->getValue(); @@ -115,7 +115,7 @@ void CodeEmitterGen::createEmitter(std::ostream &o) { << " }\n"; } o << " default:\n" - << " std::cerr << \"Not supported instr: \" << MI << \"\\n\";\n" + << " DEBUG(std::cerr << \"Not supported instr: \" << MI << \"\\n\");\n" << " abort();\n" << " }\n" << " return Value;\n"