Moved MachineCodeForBB to be an annotation on BasicBlock.
authorVikram S. Adve <vadve@cs.uiuc.edu>
Mon, 8 Jul 2002 22:31:11 +0000 (22:31 +0000)
committerVikram S. Adve <vadve@cs.uiuc.edu>
Mon, 8 Jul 2002 22:31:11 +0000 (22:31 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2818 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/BasicBlock.h
lib/VMCore/BasicBlock.cpp

index 8fc25d58d4a654022ef89dcd60f3e51492df8510..2ea5e6ad5536a3db079b6de9414bfb9d0b9fcc10 100644 (file)
@@ -25,7 +25,6 @@
 #include "Support/ilist"
 
 class TerminatorInst;
-class MachineCodeForBasicBlock;
 template <class _Term, class _BB> class SuccIterator;  // Successor Iterator
 template <class _Ptr, class _USE_iterator> class PredIterator;
 
@@ -41,7 +40,6 @@ public:
   typedef iplist<Instruction> InstListType;
 private :
   InstListType InstList;
-  MachineCodeForBasicBlock* machineInstrVec;
   BasicBlock *Prev, *Next; // Next and Prev links for our intrusive linked list
 
   void setParent(Function *parent) { InstList.setParent(parent); }
@@ -83,11 +81,6 @@ public:
   TerminatorInst *getTerminator();
   const TerminatorInst *const getTerminator() const;
   
-  // Machine code accessor...
-  inline MachineCodeForBasicBlock& getMachineInstrVec() const {
-    return *machineInstrVec; 
-  }
-
   // Provide a scoped predecessor and successor iterator
   typedef PredIterator<BasicBlock, Value::use_iterator> pred_iterator;
   typedef PredIterator<const BasicBlock, 
index 39ffdea865bea5d98609608be384f537def61221..446af17be1847fba4a313e34094bac5849f4d271 100644 (file)
@@ -11,7 +11,6 @@
 #include "llvm/Constant.h"
 #include "llvm/iPHINode.h"
 #include "llvm/SymbolTable.h"
-#include "llvm/CodeGen/MachineInstr.h"
 #include "SymbolTableListTraitsImpl.h"
 #include <algorithm>
 
@@ -47,8 +46,7 @@ template SymbolTableListTraits<Instruction, BasicBlock, Function>;
 
 
 BasicBlock::BasicBlock(const std::string &name, Function *Parent)
-  : Value(Type::LabelTy, Value::BasicBlockVal, name),
-    machineInstrVec(new MachineCodeForBasicBlock) {
+  : Value(Type::LabelTy, Value::BasicBlockVal, name) {
   // Initialize the instlist...
   InstList.setItemParent(this);
 
@@ -59,7 +57,6 @@ BasicBlock::BasicBlock(const std::string &name, Function *Parent)
 BasicBlock::~BasicBlock() {
   dropAllReferences();
   InstList.clear();
-  delete machineInstrVec;
 }
 
 // Specialize setName to take care of symbol table majik