#include "SparcInternals.h"
#include "llvm/Bytecode/Writer.h"
+#include <ostream>
namespace {
class sparcasmbuf : public streambuf {
std::ostream &BaseStr;
public:
- typedef char char_type;
- typedef int int_type;
- typedef streampos pos_type;
- typedef streamoff off_type;
+ typedef char char_type;
+ typedef int int_type;
+ typedef std::streampos pos_type;
+ typedef std::streamoff off_type;
sparcasmbuf(std::ostream &On) : BaseStr(On) {}
class osparcasmstream : public ostream {
sparcasmbuf sb;
public:
- typedef char char_type;
- typedef int int_type;
- typedef streampos pos_type;
- typedef streamoff off_type;
+ typedef char char_type;
+ typedef int int_type;
+ typedef std::streampos pos_type;
+ typedef std::streamoff off_type;
explicit osparcasmstream(ostream &On) : ostream(&sb), sb(On) { }
#include "llvm/Module.h"
#include "Support/StringExtras.h"
#include "Support/HashExtras.h"
+#include <ostream>
using std::string;
namespace {
class SparcModuleAsmPrinter : public Pass, public AsmPrinter {
public:
- SparcModuleAsmPrinter(ostream &os, TargetMachine &t) : AsmPrinter(os, t) {}
+ SparcModuleAsmPrinter(std::ostream &os, TargetMachine &t)
+ : AsmPrinter(os, t) {}
virtual bool run(Module *M) {
startModule(M);
else if (ty <= Type::DoubleTyID)
res = FloatRegClassID; // sparc float reg class
else {
- std::cerr << "TypeID: " << ty << "\n";
+ //std::cerr << "TypeID: " << ty << "\n";
assert(0 && "Cannot resolve register class for type");
return 0;
}