Add support for writing LLVM IR to a specified BitstreamWriter.

Patch by Lukasz Janyst!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61251 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Chris Lattner
2008-12-19 18:37:59 +00:00
parent 018a34c576
commit 38e7721455
3 changed files with 25 additions and 12 deletions

View File

@ -22,6 +22,7 @@ namespace llvm {
class ModuleProvider;
class MemoryBuffer;
class ModulePass;
class BitstreamWriter;
class raw_ostream;
/// getBitcodeModuleProvider - Read the header of the specified bitcode buffer
@ -45,6 +46,10 @@ namespace llvm {
/// raw output stream.
void WriteBitcodeToFile(const Module *M, raw_ostream &Out);
/// WriteBitcodeToStream - Write the specified module to the specified
/// raw output stream.
void WriteBitcodeToStream(const Module *M, BitstreamWriter &Stream);
/// CreateBitcodeWriterPass - Create and return a pass that writes the module
/// to the specified ostream.
ModulePass *CreateBitcodeWriterPass(std::ostream &Str);