mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-12-17 00:27:31 +00:00
Pretty print DBG_VALUE machine instructions.
Before: DBG_VALUE %RSI, 0, !-1; dbg:SimpleRegisterCoalescing.cpp:2707 Now: DBG_VALUE %RSI, 0, !"this"; dbg:SimpleRegisterCoalescing.cpp:2707 llvm-svn: 102518
This commit is contained in:
parent
9867c1a075
commit
fb33f168e0
@ -1187,7 +1187,15 @@ void MachineInstr::print(raw_ostream &OS, const TargetMachine *TM) const {
|
||||
if (TOI.isOptionalDef())
|
||||
OS << "opt:";
|
||||
}
|
||||
MO.print(OS, TM);
|
||||
if (isDebugValue() && MO.isMetadata()) {
|
||||
// Pretty print DBG_VALUE instructions.
|
||||
const MDNode *MD = MO.getMetadata();
|
||||
if (const MDString *MDS = dyn_cast<MDString>(MD->getOperand(2)))
|
||||
OS << "!\"" << MDS->getString() << '\"';
|
||||
else
|
||||
MO.print(OS, TM);
|
||||
} else
|
||||
MO.print(OS, TM);
|
||||
}
|
||||
|
||||
// Briefly indicate whether any call clobbers were omitted.
|
||||
|
Loading…
Reference in New Issue
Block a user