diff options
author | Richard Barton <richard.barton@arm.com> | 2012-04-27 08:42:59 +0000 |
---|---|---|
committer | Richard Barton <richard.barton@arm.com> | 2012-04-27 08:42:59 +0000 |
commit | 4d2f077df1b46a126b5595d983f233ec896b757e (patch) | |
tree | 1536356ef670a6b89ca0b7b2ba907f637c3e4e81 /lib/Target/ARM/InstPrinter/ARMInstPrinter.cpp | |
parent | d213ee764341b5bf6664469a5404fe19c9732828 (diff) | |
download | external_llvm-4d2f077df1b46a126b5595d983f233ec896b757e.tar.gz external_llvm-4d2f077df1b46a126b5595d983f233ec896b757e.tar.bz2 external_llvm-4d2f077df1b46a126b5595d983f233ec896b757e.zip |
Refactor IT handling not to store the bottom bit of the condition code in the mask operand in the MCInst.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@155700 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/ARM/InstPrinter/ARMInstPrinter.cpp')
-rw-r--r-- | lib/Target/ARM/InstPrinter/ARMInstPrinter.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/Target/ARM/InstPrinter/ARMInstPrinter.cpp b/lib/Target/ARM/InstPrinter/ARMInstPrinter.cpp index cbd81c11a4..34a76b27ea 100644 --- a/lib/Target/ARM/InstPrinter/ARMInstPrinter.cpp +++ b/lib/Target/ARM/InstPrinter/ARMInstPrinter.cpp @@ -754,7 +754,8 @@ void ARMInstPrinter::printThumbITMask(const MCInst *MI, unsigned OpNum, raw_ostream &O) { // (3 - the number of trailing zeros) is the number of then / else. unsigned Mask = MI->getOperand(OpNum).getImm(); - unsigned CondBit0 = Mask >> 4 & 1; + unsigned Firstcond = MI->getOperand(OpNum-1).getImm(); + unsigned CondBit0 = Firstcond & 1; unsigned NumTZ = CountTrailingZeros_32(Mask); assert(NumTZ <= 3 && "Invalid IT mask!"); for (unsigned Pos = 3, e = NumTZ; Pos > e; --Pos) { |