Add support for writing bytecode files with compactiontables for bytecode files.
This shrinks the bytecode file for 176.gcc by about 200K (10%), and 254.gap by
about 167K, a 25% reduction. There is still a lot of room for improvement in
the encoding of the compaction table.
llvm-svn: 10915
diff --git a/llvm/lib/Bytecode/Writer/WriterInternals.h b/llvm/lib/Bytecode/Writer/WriterInternals.h
index 15dbeff..1e47f5e 100644
--- a/llvm/lib/Bytecode/Writer/WriterInternals.h
+++ b/llvm/lib/Bytecode/Writer/WriterInternals.h
@@ -37,7 +37,12 @@
void outputConstants(bool isFunction);
void outputConstantStrings();
void outputFunction(const Function *F);
- void processInstruction(const Instruction &I);
+ void outputCompactionTable();
+ void outputCompactionTablePlane(unsigned PlaneNo,
+ const std::vector<const Value*> &TypePlane,
+ unsigned StartNo);
+ void outputInstructions(const Function *F);
+ void outputInstruction(const Instruction &I);
void outputModuleInfoBlock(const Module *C);
void outputSymbolTable(const SymbolTable &ST);