X-Git-Url: http://demsky.eecs.uci.edu/git/?a=blobdiff_plain;f=lib%2FMC%2FMCInst.cpp;h=124cc149beb63b856e46efac195e399242223a47;hb=8a2ce5d32987f99185f40eb3085a8972291f8d5c;hp=ec97acc554f5786c85263523a67f4ecd58a02bf8;hpb=ede042dc8d59ff48a48ef8e2271f2a7ee8324ba5;p=oota-llvm.git diff --git a/lib/MC/MCInst.cpp b/lib/MC/MCInst.cpp index ec97acc554f..124cc149beb 100644 --- a/lib/MC/MCInst.cpp +++ b/lib/MC/MCInst.cpp @@ -25,15 +25,19 @@ void MCOperand::print(raw_ostream &OS, const MCAsmInfo *MAI) const { OS << "Imm:" << getImm(); else if (isExpr()) { OS << "Expr:(" << *getExpr() << ")"; + } else if (isInst()) { + OS << "Inst:(" << *getInst() << ")"; } else OS << "UNDEFINED"; OS << ">"; } +#if !defined(NDEBUG) || defined(LLVM_ENABLE_DUMP) void MCOperand::dump() const { print(dbgs(), 0); dbgs() << "\n"; } +#endif void MCInst::print(raw_ostream &OS, const MCAsmInfo *MAI) const { OS << ""; } @@ -67,21 +61,12 @@ void MCInst::dump_pretty(raw_ostream &OS, const MCAsmInfo *MAI, OS << Separator; getOperand(i).print(OS, MAI); } - - if (getNumAnnotations()) { - OS << " # Annots: "; - for (unsigned i = 0, e = getNumAnnotations(); i != e; ++i) { - OS << Separator; - OS << '"'; - OS << getAnnotation(i); - OS << '"'; - } - } - OS << ">"; } +#if !defined(NDEBUG) || defined(LLVM_ENABLE_DUMP) void MCInst::dump() const { print(dbgs(), 0); dbgs() << "\n"; } +#endif