Rllvm (version 0.7-0)

getPassManager: Create an LLVM pass manager

Description

This function returns an instance of an LLVM FunctionPassManager as an object of R class FunctionPassManager which is just a reference to the C++ object. This is used when optimizing code via Optimize for either a Function or a Module.

Usage

getPassManager(module, execEngine = ExecutionEngine(module), level = 3L)
passManager(module, functionManager = !missing(module))

Arguments

module

the module for which the pass manager is to be created and associated.

execEngine

an instance of the ExecutionEngine. This is used to determine the data layout for the particular platform which is needed for optimization. This can be NULL in which case the data layout element/step of the pass manager is omitted.

level

optimization level

functionManager

whether to create a FunctionPassManager object or a just a PassManager

Value

An object of class FunctionPassManager.

References

The LLVM API documentation

See Also

Optimize

Examples

Run this code
# NOT RUN {
 # See the code in experiments/ in the source package.
# }

Run the code above in your browser using DataLab