llvm-hs-5.1.3: General purpose LLVM bindings

Safe HaskellNone
LanguageHaskell98

LLVM.PassManager

Description

A PassManager holds collection of passes, to be run on Modules. Build one with withPassManager:

Synopsis

Documentation

data PassManager Source #

http://llvm.org/doxygen/classllvm_1_1PassManager.html Note: a PassManager does substantive behind-the-scenes work, arranging for the results of various analyses to be available as needed by transform passes, shared as possible.

data PassSetSpec Source #

There are different ways to get a PassManager. This type embodies them.

Constructors

PassSetSpec

a PassSetSpec is a lower-level, detailed specification of a set of passes. It allows fine-grained control of what passes are to be run when, and the specification of passes not available through CuratedPassSetSpec.

CuratedPassSetSpec

This type is a high-level specification of a set of passes. It uses the same collection of passes chosen by the LLVM team in the command line tool opt. The fields of this spec are much like typical compiler command-line flags - e.g. -O<n>, etc.

withPassManager :: PassSetSpec -> (PassManager -> IO a) -> IO a Source #

bracket the creation of a PassManager

runPassManager :: PassManager -> Module -> IO Bool Source #

run the passes in a PassManager on a Module, modifying the Module.