Add Thumb HVC and ERET virtualisation extension instructions.

Patch by Matthew Wahab.

Change-Id: I131f71c1150d5fa797066a18e09d526c19bf9016

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@222990 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Charlie Turner
2014-12-01 08:39:19 +00:00
parent 42563acbd4
commit eed2e8bf98
4 changed files with 156 additions and 0 deletions

View File

@@ -291,6 +291,21 @@ void ARMInstPrinter::printInst(const MCInst *MI, raw_ostream &O,
return;
}
break;
}
// B9.3.3 ERET (Thumb)
// For a target that has Virtualization Extensions, ERET is the preferred
// disassembly of SUBS PC, LR, #0
case ARM::t2SUBS_PC_LR: {
if (MI->getNumOperands() == 3 &&
MI->getOperand(0).isImm() &&
MI->getOperand(0).getImm() == 0 &&
(getAvailableFeatures() & ARM::FeatureVirtualization)) {
O << "\teret";
printPredicateOperand(MI, 1, O);
printAnnotation(O, Annot);
return;
}
break;
}
}