summaryrefslogtreecommitdiff
path: root/lib/CodeGen/AsmPrinter.cpp
diff options
context:
space:
mode:
authorBill Wendling <isanbard@gmail.com>2006-12-07 01:30:32 +0000
committerBill Wendling <isanbard@gmail.com>2006-12-07 01:30:32 +0000
commite81561909d128c6e2d8033cb5465a49b2596b26a (patch)
tree6f2845604d482bc86d8d12aae500292c561d8cd7 /lib/CodeGen/AsmPrinter.cpp
parent85c671b90870705ba7e10baf99aa306c843f1325 (diff)
downloadllvm-e81561909d128c6e2d8033cb5465a49b2596b26a.tar.gz
llvm-e81561909d128c6e2d8033cb5465a49b2596b26a.tar.bz2
llvm-e81561909d128c6e2d8033cb5465a49b2596b26a.tar.xz
Changed llvm_ostream et all to OStream. llvm_cerr, llvm_cout, llvm_null, are
now cerr, cout, and NullStream resp. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32298 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/AsmPrinter.cpp')
-rw-r--r--lib/CodeGen/AsmPrinter.cpp37
1 files changed, 18 insertions, 19 deletions
diff --git a/lib/CodeGen/AsmPrinter.cpp b/lib/CodeGen/AsmPrinter.cpp
index 1b25b015fa..4caa2c1be1 100644
--- a/lib/CodeGen/AsmPrinter.cpp
+++ b/lib/CodeGen/AsmPrinter.cpp
@@ -25,7 +25,6 @@
#include "llvm/Target/TargetData.h"
#include "llvm/Target/TargetLowering.h"
#include "llvm/Target/TargetMachine.h"
-#include <ostream>
#include <cerrno>
using namespace llvm;
@@ -668,8 +667,8 @@ void AsmPrinter::PrintSpecial(const MachineInstr *MI, const char *Code) {
if (LastMI != MI) { ++Counter; LastMI = MI; }
O << Counter;
} else {
- llvm_cerr << "Unknown special formatter '" << Code
- << "' for machine instr: " << *MI;
+ cerr << "Unknown special formatter '" << Code
+ << "' for machine instr: " << *MI;
exit(1);
}
}
@@ -737,8 +736,8 @@ void AsmPrinter::printInlineAsm(const MachineInstr *MI) const {
case '(': // $( -> same as GCC's { character.
++LastEmitted; // Consume '(' character.
if (CurVariant != -1) {
- llvm_cerr << "Nested variants found in inline asm string: '"
- << AsmStr << "'\n";
+ cerr << "Nested variants found in inline asm string: '"
+ << AsmStr << "'\n";
exit(1);
}
CurVariant = 0; // We're in the first variant now.
@@ -746,8 +745,8 @@ void AsmPrinter::printInlineAsm(const MachineInstr *MI) const {
case '|':
++LastEmitted; // consume '|' character.
if (CurVariant == -1) {
- llvm_cerr << "Found '|' character outside of variant in inline asm "
- << "string: '" << AsmStr << "'\n";
+ cerr << "Found '|' character outside of variant in inline asm "
+ << "string: '" << AsmStr << "'\n";
exit(1);
}
++CurVariant; // We're in the next variant.
@@ -755,8 +754,8 @@ void AsmPrinter::printInlineAsm(const MachineInstr *MI) const {
case ')': // $) -> same as GCC's } char.
++LastEmitted; // consume ')' character.
if (CurVariant == -1) {
- llvm_cerr << "Found '}' character outside of variant in inline asm "
- << "string: '" << AsmStr << "'\n";
+ cerr << "Found '}' character outside of variant in inline asm "
+ << "string: '" << AsmStr << "'\n";
exit(1);
}
CurVariant = -1;
@@ -774,8 +773,8 @@ void AsmPrinter::printInlineAsm(const MachineInstr *MI) const {
char *IDEnd;
long Val = strtol(IDStart, &IDEnd, 10); // We only accept numbers for IDs.
if (!isdigit(*IDStart) || (Val == 0 && errno == EINVAL)) {
- llvm_cerr << "Bad $ operand number in inline asm string: '"
- << AsmStr << "'\n";
+ cerr << "Bad $ operand number in inline asm string: '"
+ << AsmStr << "'\n";
exit(1);
}
LastEmitted = IDEnd;
@@ -788,8 +787,8 @@ void AsmPrinter::printInlineAsm(const MachineInstr *MI) const {
if (*LastEmitted == ':') {
++LastEmitted; // Consume ':' character.
if (*LastEmitted == 0) {
- llvm_cerr << "Bad ${:} expression in inline asm string: '"
- << AsmStr << "'\n";
+ cerr << "Bad ${:} expression in inline asm string: '"
+ << AsmStr << "'\n";
exit(1);
}
@@ -798,16 +797,16 @@ void AsmPrinter::printInlineAsm(const MachineInstr *MI) const {
}
if (*LastEmitted != '}') {
- llvm_cerr << "Bad ${} expression in inline asm string: '"
- << AsmStr << "'\n";
+ cerr << "Bad ${} expression in inline asm string: '"
+ << AsmStr << "'\n";
exit(1);
}
++LastEmitted; // Consume '}' character.
}
if ((unsigned)Val >= NumOperands-1) {
- llvm_cerr << "Invalid $ operand number in inline asm string: '"
- << AsmStr << "'\n";
+ cerr << "Invalid $ operand number in inline asm string: '"
+ << AsmStr << "'\n";
exit(1);
}
@@ -841,8 +840,8 @@ void AsmPrinter::printInlineAsm(const MachineInstr *MI) const {
}
}
if (Error) {
- llvm_cerr << "Invalid operand found in inline asm: '"
- << AsmStr << "'\n";
+ cerr << "Invalid operand found in inline asm: '"
+ << AsmStr << "'\n";
MI->dump();
exit(1);
}