diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2019-06-11 18:16:27 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2019-06-11 18:16:27 +0000 |
commit | 687a64222b4c87c825258d4dfeb1f0794e8cb300 (patch) | |
tree | f15e528223c9e06e4ed874e21ad41c2eb169030b /lib/Target/PowerPC/InstPrinter/PPCInstPrinter.cpp | |
parent | 24eadf6f46cd3637ffe867648ce8eca7314115c6 (diff) |
vendor/llvm/llvm-release_801-r366581vendor/llvm/llvm-release_80-r364487vendor/llvm/llvm-release_80-r363030vendor/llvm-80
Notes
Diffstat (limited to 'lib/Target/PowerPC/InstPrinter/PPCInstPrinter.cpp')
-rw-r--r-- | lib/Target/PowerPC/InstPrinter/PPCInstPrinter.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/lib/Target/PowerPC/InstPrinter/PPCInstPrinter.cpp b/lib/Target/PowerPC/InstPrinter/PPCInstPrinter.cpp index fc29e4effbb1..6824168b890d 100644 --- a/lib/Target/PowerPC/InstPrinter/PPCInstPrinter.cpp +++ b/lib/Target/PowerPC/InstPrinter/PPCInstPrinter.cpp @@ -382,8 +382,11 @@ void PPCInstPrinter::printBranchOperand(const MCInst *MI, unsigned OpNo, // Branches can take an immediate operand. This is used by the branch // selection pass to print .+8, an eight byte displacement from the PC. - O << ".+"; - printAbsBranchOperand(MI, OpNo, O); + O << "."; + int32_t Imm = SignExtend32<32>((unsigned)MI->getOperand(OpNo).getImm() << 2); + if (Imm >= 0) + O << "+"; + O << Imm; } void PPCInstPrinter::printAbsBranchOperand(const MCInst *MI, unsigned OpNo, |