Initialize IsDef of all non-register MachineOperand to false.
[oota-llvm.git] / include / llvm / Instruction.h
index ef6285261d06028e76afc6b9d5e8953c55def2f6..dd73213878f5d9f189dc299ca9a5c9f56a359cb8 100644 (file)
@@ -27,6 +27,9 @@ template<typename ValueSubClass, typename ItemParentClass, typename SymTabClass,
          typename SubClass> class SymbolTableListTraits;
 
 class Instruction : public User {
+  void operator=(const Instruction &);     // Do not implement
+  Instruction(const Instruction &);        // Do not implement
+
   BasicBlock *Parent;
   Instruction *Prev, *Next; // Next and Prev links for our intrusive linked list
 
@@ -49,11 +52,9 @@ protected:
   Instruction(const Type *Ty, unsigned iType, Use *Ops, unsigned NumOps,
               const std::string &Name, BasicBlock *InsertAtEnd);
 public:
-
-  ~Instruction() {
-    assert(Parent == 0 && "Instruction still linked in the program!");
-  }
-
+  // Out of line virtual method, so the vtable, etc has a home.
+  ~Instruction();
+  
   /// mayWriteToMemory - Return true if this instruction may modify memory.
   ///
   virtual bool mayWriteToMemory() const { return false; }
@@ -103,7 +104,7 @@ public:
   /// one of the enums that is coming soon (down below)...
   ///
   unsigned getOpcode() const { return getValueType() - InstructionVal; }
-  virtual const char *getOpcodeName() const {
+  const char *getOpcodeName() const {
     return getOpcodeName(getOpcode());
   }
   static const char* getOpcodeName(unsigned OpCode);
@@ -157,7 +158,7 @@ public:
   void print(std::ostream &OS, AssemblyAnnotationWriter *AAW) const;
 
   /// Methods for support type inquiry through isa, cast, and dyn_cast:
-  static inline bool classof(const Instruction *I) { return true; }
+  static inline bool classof(const Instruction *) { return true; }
   static inline bool classof(const Value *V) {
     return V->getValueType() >= Value::InstructionVal;
   }