For PR411:
[oota-llvm.git] / lib / Bytecode / Reader / Reader.h
index 3e64f2d027d59890e6b2550f245c0b49b5198872..b881f9d0a566c1441c04852848265193c1e9e955 100644 (file)
 
 namespace llvm {
 
-class BytecodeHandler; ///< Forward declare the handler interface
-class TypeSymbolTable; ///< Forward declare
+// Forward declarations
+class BytecodeHandler; 
+class TypeSymbolTable; 
+class ValueSymbolTable; 
 
 /// This class defines the interface for parsing a buffer of bytecode. The
 /// parser itself takes no action except to call the various functions of
@@ -204,7 +206,7 @@ protected:
   void ParseTypeSymbolTable(TypeSymbolTable *ST);
 
   /// @brief Parse a value symbol table
-  void ParseValueSymbolTable(Function* Func, SymbolTable *ST);
+  void ParseValueSymbolTable(Function* Func, ValueSymbolTable *ST);
 
   /// @brief Parse functions lazily.
   void ParseFunctionLazily();
@@ -212,12 +214,6 @@ protected:
   ///  @brief Parse a function body
   void ParseFunctionBody(Function* Func);
 
-  /// @brief Parse the type list portion of a compaction table
-  void ParseCompactionTypes(unsigned NumEntries);
-
-  /// @brief Parse a compaction table
-  void ParseCompactionTable();
-
   /// @brief Parse global types
   void ParseGlobalTypes();
 
@@ -275,15 +271,6 @@ private:
   ///
   unsigned char RevisionNum;        // The rev # itself
 
-  /// CompactionTypes - If a compaction table is active in the current function,
-  /// this is the mapping that it contains.  We keep track of what resolved type
-  /// it is as well as what global type entry it is.
-  std::vector<std::pair<const Type*, unsigned> > CompactionTypes;
-
-  /// @brief If a compaction table is active in the current function,
-  /// this is the mapping that it contains.
-  std::vector<std::vector<Value*> > CompactionValues;
-
   /// @brief This vector is used to deal with forward references to types in
   /// a module.
   TypeListTy ModuleTypes;
@@ -363,23 +350,12 @@ private:
   /// @brief Converts a Type* to its type slot number
   unsigned getTypeSlot(const Type *Ty);
 
-  /// @brief Converts a normal type slot number to a compacted type slot num.
-  unsigned getCompactionTypeSlot(unsigned type);
-
   /// @brief Gets the global type corresponding to the TypeId
   const Type *getGlobalTableType(unsigned TypeId);
 
-  /// This is just like getTypeSlot, but when a compaction table is in use,
-  /// it is ignored.
-  unsigned getGlobalTableTypeSlot(const Type *Ty);
-
   /// @brief Get a value from its typeid and slot number
   Value* getValue(unsigned TypeID, unsigned num, bool Create = true);
 
-  /// @brief Get a value from its type and slot number, ignoring compaction
-  /// tables.
-  Value *getGlobalTableValue(unsigned TyID, unsigned SlotNo);
-
   /// @brief Get a basic block for current function
   BasicBlock *getBasicBlock(unsigned ID);