1 //===-- llvm/Assembly/Writer.h - Printer for VM assembly files ---*- C++ -*--=//
3 // This functionality is implemented by the lib/Assembly/Writer library.
4 // This library is used to print VM assembly language files to an iostream. It
5 // can print VM code at a variety of granularities, ranging from a whole class
6 // down to an individual instruction. This makes it useful for debugging.
8 // This file also defines functions that allow it to output files that a program
9 // called VCG can read.
11 // This library uses the Analysis library to figure out offsets for
12 // variables in the method tables...
14 //===----------------------------------------------------------------------===//
16 #ifndef LLVM_ASSEMBLY_WRITER_H
17 #define LLVM_ASSEMBLY_WRITER_H
25 // WriteTypeSymbolic - This attempts to write the specified type as a symbolic
26 // type, iff there is an entry in the modules symbol table for the specified
27 // type or one of it's component types. This is slower than a simple x << Type;
29 std::ostream &WriteTypeSymbolic(std::ostream &, const Type *, const Module *M);
32 // WriteAsOperand - Write the name of the specified value out to the specified
33 // ostream. This can be useful when you just want to print int %reg126, not the
34 // whole instruction that generated it. If you specify a Module for context,
35 // then even constants get pretty printed (for example the type of a null
36 // pointer is printed symbolically).
38 std::ostream &WriteAsOperand(std::ostream &, const Value *, bool PrintTy = true,
39 bool PrintName = true, const Module *Context = 0);