Further progration of metadata operands. The

dumper doesn't really do what I want yet, but
at least it doesn't crash now.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@93272 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Dale Johannesen
2010-01-13 00:00:24 +00:00
parent 994a204570
commit 5f72a5ebc8
4 changed files with 19 additions and 2 deletions

View File

@ -34,6 +34,7 @@
#include "llvm/Support/MathExtras.h"
#include "llvm/Support/raw_ostream.h"
#include "llvm/ADT/FoldingSet.h"
#include "llvm/Metadata.h"
using namespace llvm;
//===----------------------------------------------------------------------===//
@ -278,10 +279,15 @@ void MachineOperand::print(raw_ostream &OS, const TargetMachine *TM) const {
OS << '>';
break;
case MachineOperand::MO_BlockAddress:
OS << "<";
OS << '<';
WriteAsOperand(OS, getBlockAddress(), /*PrintType=*/false);
OS << '>';
break;
case MachineOperand::MO_Metadata:
OS << '<';
WriteAsOperand(OS, getMetadata(), /*PrintType=*/false);
OS << '>';
break;
default:
llvm_unreachable("Unrecognized operand type");
}