mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-24 22:24:54 +00:00
Re-commit r98683 ("remove redundant writeback flag from ARM address mode 6")
with changes to add a separate optional register update argument. Change all the NEON instructions with address register writeback to use it. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@99095 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -428,17 +428,22 @@ void ARMInstPrinter::printAddrMode5Operand(const MCInst *MI, unsigned OpNum,
|
||||
void ARMInstPrinter::printAddrMode6Operand(const MCInst *MI, unsigned OpNum) {
|
||||
const MCOperand &MO1 = MI->getOperand(OpNum);
|
||||
const MCOperand &MO2 = MI->getOperand(OpNum+1);
|
||||
const MCOperand &MO3 = MI->getOperand(OpNum+2);
|
||||
|
||||
// FIXME: No support yet for specifying alignment.
|
||||
O << '[' << getRegisterName(MO1.getReg()) << ']';
|
||||
|
||||
if (ARM_AM::getAM6WBFlag(MO3.getImm())) {
|
||||
if (MO2.getReg() == 0)
|
||||
O << '!';
|
||||
else
|
||||
O << ", " << getRegisterName(MO2.getReg());
|
||||
O << "[" << getRegisterName(MO1.getReg());
|
||||
if (MO2.getImm()) {
|
||||
// FIXME: Both darwin as and GNU as violate ARM docs here.
|
||||
O << ", :" << MO2.getImm();
|
||||
}
|
||||
O << "]";
|
||||
}
|
||||
|
||||
void ARMInstPrinter::printAddrMode6OffsetOperand(const MCInst *MI,
|
||||
unsigned OpNum) {
|
||||
const MCOperand &MO = MI->getOperand(OpNum);
|
||||
if (MO.getReg() == 0)
|
||||
O << "!";
|
||||
else
|
||||
O << ", " << getRegisterName(MO.getReg());
|
||||
}
|
||||
|
||||
void ARMInstPrinter::printAddrModePCOperand(const MCInst *MI, unsigned OpNum,
|
||||
|
Reference in New Issue
Block a user