diff options
| author | Dimitry Andric <dim@FreeBSD.org> | 2013-04-08 18:41:23 +0000 | 
|---|---|---|
| committer | Dimitry Andric <dim@FreeBSD.org> | 2013-04-08 18:41:23 +0000 | 
| commit | 4a16efa3e43e35f0cc9efe3a67f620f0017c3d36 (patch) | |
| tree | 06099edc18d30894081a822b756f117cbe0b8207 /lib/Target/X86/InstPrinter/X86ATTInstPrinter.cpp | |
| parent | 482e7bddf617ae804dc47133cb07eb4aa81e45de (diff) | |
Diffstat (limited to 'lib/Target/X86/InstPrinter/X86ATTInstPrinter.cpp')
| -rw-r--r-- | lib/Target/X86/InstPrinter/X86ATTInstPrinter.cpp | 12 | 
1 files changed, 6 insertions, 6 deletions
| diff --git a/lib/Target/X86/InstPrinter/X86ATTInstPrinter.cpp b/lib/Target/X86/InstPrinter/X86ATTInstPrinter.cpp index a4bd1147bc51..e357710b20eb 100644 --- a/lib/Target/X86/InstPrinter/X86ATTInstPrinter.cpp +++ b/lib/Target/X86/InstPrinter/X86ATTInstPrinter.cpp @@ -14,12 +14,12 @@  #define DEBUG_TYPE "asm-printer"  #include "X86ATTInstPrinter.h" -#include "X86InstComments.h"  #include "MCTargetDesc/X86BaseInfo.h"  #include "MCTargetDesc/X86MCTargetDesc.h" -#include "llvm/MC/MCInst.h" +#include "X86InstComments.h"  #include "llvm/MC/MCAsmInfo.h"  #include "llvm/MC/MCExpr.h" +#include "llvm/MC/MCInst.h"  #include "llvm/MC/MCInstrInfo.h"  #include "llvm/MC/MCRegisterInfo.h"  #include "llvm/Support/ErrorHandling.h" @@ -131,7 +131,7 @@ void X86ATTInstPrinter::printPCRelImm(const MCInst *MI, unsigned OpNo,                                        raw_ostream &O) {    const MCOperand &Op = MI->getOperand(OpNo);    if (Op.isImm()) -    O << Op.getImm(); +    O << formatImm(Op.getImm());    else {      assert(Op.isExpr() && "unknown pcrel immediate operand");      // If a symbolic branch target was added as a constant expression then print @@ -157,7 +157,7 @@ void X86ATTInstPrinter::printOperand(const MCInst *MI, unsigned OpNo,    } else if (Op.isImm()) {      // Print X86 immediates as signed values.      O << markup("<imm:") -      << '$' << (int64_t)Op.getImm() +      << '$' << formatImm((int64_t)Op.getImm())        << markup(">");      if (CommentStream && (Op.getImm() > 255 || Op.getImm() < -256)) @@ -189,7 +189,7 @@ void X86ATTInstPrinter::printMemReference(const MCInst *MI, unsigned Op,    if (DispSpec.isImm()) {      int64_t DispVal = DispSpec.getImm();      if (DispVal || (!IndexReg.getReg() && !BaseReg.getReg())) -      O << DispVal; +      O << formatImm(DispVal);    } else {      assert(DispSpec.isExpr() && "non-immediate displacement for LEA?");      O << *DispSpec.getExpr(); @@ -207,7 +207,7 @@ void X86ATTInstPrinter::printMemReference(const MCInst *MI, unsigned Op,        if (ScaleVal != 1) {          O << ','  	  << markup("<imm:") -          << ScaleVal +          << ScaleVal // never printed in hex.  	  << markup(">");        }      } | 
