1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-24 11:42:57 +01:00

Identify predicate and optional-def operands when printing machine

instructions.

llvm-svn: 93925
This commit is contained in:
Jakob Stoklund Olesen 2010-01-19 22:08:34 +00:00
parent 20c1857075
commit b93c3b9624

View File

@ -1162,6 +1162,13 @@ void MachineInstr::print(raw_ostream &OS, const TargetMachine *TM) const {
if (FirstOp) FirstOp = false; else OS << ",";
OS << " ";
if (i < getDesc().NumOperands) {
const TargetOperandInfo &TOI = getDesc().OpInfo[i];
if (TOI.isPredicate())
OS << "pred:";
if (TOI.isOptionalDef())
OS << "opt:";
}
MO.print(OS, TM);
}