LLVM
8.0.1
|
Eager IR compiling layer. More...
#include "llvm/ExecutionEngine/Orc/IRCompileLayer.h"
Public Types | |
using | NotifyCompiledCallback = std::function< void(VModuleKey K, std::unique_ptr< Module >)> |
Callback type for notifications when modules are compiled. More... | |
Public Member Functions | |
LegacyIRCompileLayer (BaseLayerT &BaseLayer, CompileFtor Compile, NotifyCompiledCallback NotifyCompiled=NotifyCompiledCallback()) | |
Construct an LegacyIRCompileLayer with the given BaseLayer, which must implement the ObjectLayer concept. More... | |
CompileFtor & | getCompiler () |
Get a reference to the compiler functor. More... | |
void | setNotifyCompiled (NotifyCompiledCallback NotifyCompiled) |
(Re)set the NotifyCompiled callback. More... | |
Error | addModule (VModuleKey K, std::unique_ptr< Module > M) |
Compile the module, and add the resulting object to the base layer along with the given memory manager and symbol resolver. More... | |
Error | removeModule (VModuleKey K) |
Remove the module associated with the VModuleKey K. More... | |
JITSymbol | findSymbol (const std::string &Name, bool ExportedSymbolsOnly) |
Search for the given named symbol. More... | |
JITSymbol | findSymbolIn (VModuleKey K, const std::string &Name, bool ExportedSymbolsOnly) |
Get the address of the given symbol in compiled module represented by the handle H. More... | |
Error | emitAndFinalize (VModuleKey K) |
Immediately emit and finalize the module represented by the given handle. More... | |
Eager IR compiling layer.
This layer immediately compiles each IR module added via addModule to an object file and adds this module file to the layer below, which must implement the object layer concept.
Definition at line 59 of file IRCompileLayer.h.
using llvm::orc::LegacyIRCompileLayer< BaseLayerT, CompileFtor >::NotifyCompiledCallback = std::function<void(VModuleKey K, std::unique_ptr<Module>)> |
Callback type for notifications when modules are compiled.
Definition at line 63 of file IRCompileLayer.h.
|
inline |
Construct an LegacyIRCompileLayer with the given BaseLayer, which must implement the ObjectLayer concept.
Definition at line 67 of file IRCompileLayer.h.
|
inline |
Compile the module, and add the resulting object to the base layer along with the given memory manager and symbol resolver.
Definition at line 83 of file IRCompileLayer.h.
|
inline |
Immediately emit and finalize the module represented by the given handle.
K | The VModuleKey for the module to emit/finalize. |
Definition at line 118 of file IRCompileLayer.h.
|
inline |
Search for the given named symbol.
Name | The name of the symbol to search for. |
ExportedSymbolsOnly | If true, search only for exported symbols. |
Definition at line 98 of file IRCompileLayer.h.
|
inline |
Get the address of the given symbol in compiled module represented by the handle H.
This call is forwarded to the base layer's implementation.
K | The VModuleKey for the module to search in. |
Name | The name of the symbol to search for. |
ExportedSymbolsOnly | If true, search only for exported symbols. |
Definition at line 110 of file IRCompileLayer.h.
|
inline |
Get a reference to the compiler functor.
Definition at line 74 of file IRCompileLayer.h.
|
inline |
Remove the module associated with the VModuleKey K.
Definition at line 92 of file IRCompileLayer.h.
|
inline |
(Re)set the NotifyCompiled callback.
Definition at line 77 of file IRCompileLayer.h.