R600/SI: Prettier display of input modifiers

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208479 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Vincent Lejeune
2014-05-10 19:18:33 +00:00
parent d19e830174
commit 3378ca7d5c
10 changed files with 82 additions and 41 deletions

View File

@@ -158,6 +158,18 @@ void AMDGPUInstPrinter::printOperand(const MCInst *MI, unsigned OpNo,
}
}
void AMDGPUInstPrinter::printOperandAndMods(const MCInst *MI, unsigned OpNo,
raw_ostream &O) {
unsigned InputModifiers = MI->getOperand(OpNo).getImm();
if (InputModifiers & 0x1)
O << "-";
if (InputModifiers & 0x2)
O << "|";
printOperand(MI, OpNo + 1, O);
if (InputModifiers & 0x2)
O << "|";
}
void AMDGPUInstPrinter::printInterpSlot(const MCInst *MI, unsigned OpNum,
raw_ostream &O) {
unsigned Imm = MI->getOperand(OpNum).getImm();