1 //===-- llvm/Bytecode/Writer.h - Writer for VM bytecode files ---*- C++ -*-===//
3 // The LLVM Compiler Infrastructure
5 // This file was developed by the LLVM research group and is distributed under
6 // the University of Illinois Open Source License. See LICENSE.TXT for details.
8 //===----------------------------------------------------------------------===//
10 // This functionality is implemented by the lib/BytecodeWriter library.
11 // This library is used to write VM bytecode files to an iostream. First, you
12 // have to make a BytecodeStream object, which you can then put a class into
13 // by using operator <<.
15 // This library uses the Analysis library to figure out offsets for
16 // variables in the method tables...
18 // Note that performance of this library is not as crucial as performance of the
19 // bytecode reader (which is to be used in JIT type applications), so we have
20 // designed the bytecode format to support quick reading.
22 //===----------------------------------------------------------------------===//
24 #ifndef LLVM_BYTECODE_WRITER_H
25 #define LLVM_BYTECODE_WRITER_H
31 void WriteBytecodeToFile(const Module *M, std::ostream &Out,
32 bool compress = true);
33 } // End llvm namespace