Added implict operand printing for operator( ostream, MachineInstr&)
llvm-svn: 912
diff --git a/llvm/lib/CodeGen/MachineInstr.cpp b/llvm/lib/CodeGen/MachineInstr.cpp
index 76fd4e7..2ec791f 100644
--- a/llvm/lib/CodeGen/MachineInstr.cpp
+++ b/llvm/lib/CodeGen/MachineInstr.cpp
@@ -19,6 +19,7 @@
#include "llvm/Instruction.h"
+
//************************ Class Implementations **************************/
// Constructor for instructions with fixed #operands (nearly all)
@@ -100,6 +101,25 @@
}
#endif
+
+
+#if 1
+ // code for printing implict references
+
+ unsigned NumOfImpRefs = minstr.getNumImplicitRefs();
+ if( NumOfImpRefs > 0 ) {
+
+ os << "\tImplicit:";
+
+ for(unsigned z=0; z < NumOfImpRefs; z++) {
+ os << minstr.getImplicitRef(z);
+ cout << "\t";
+ }
+ }
+
+#endif
+
+
os << endl;
return os;