|
LLVM
4.0.0
|
Compile-on-demand layer. More...
#include <CompileOnDemandLayer.h>
Public Types | |
| typedef LogicalDylibList::iterator | ModuleSetHandleT |
| Handle to a set of loaded modules. More... | |
| typedef std::function < std::set< Function * > Function &)> | PartitioningFtor |
| Module partitioning functor. More... | |
| typedef std::function < std::unique_ptr < IndirectStubsMgrT >)> | IndirectStubsManagerBuilderT |
| Builder for IndirectStubsManagers. More... | |
Public Member Functions | |
| CompileOnDemandLayer (BaseLayerT &BaseLayer, PartitioningFtor Partition, CompileCallbackMgrT &CallbackMgr, IndirectStubsManagerBuilderT CreateIndirectStubsManager, bool CloneStubsIntoPartitions=true) | |
| Construct a compile-on-demand layer instance. More... | |
| template<typename ModuleSetT , typename MemoryManagerPtrT , typename SymbolResolverPtrT > | |
| ModuleSetHandleT | addModuleSet (ModuleSetT Ms, MemoryManagerPtrT MemMgr, SymbolResolverPtrT Resolver) |
| Add a module to the compile-on-demand layer. More... | |
| void | removeModuleSet (ModuleSetHandleT H) |
| Remove the module represented by the given handle. More... | |
| JITSymbol | findSymbol (StringRef Name, bool ExportedSymbolsOnly) |
| Search for the given named symbol. More... | |
| JITSymbol | findSymbolIn (ModuleSetHandleT H, const std::string &Name, bool ExportedSymbolsOnly) |
| Get the address of a symbol provided by this layer, or some layer below this one. More... | |
| bool | updatePointer (std::string FuncName, JITTargetAddress FnBodyAddr) |
| Update the stub for the given function to point at FnBodyAddr. More... | |
Compile-on-demand layer.
When a module is added to this layer a stub is created for each of its function definitions. The stubs and other global values are immediately added to the layer below. When a stub is called it triggers the extraction of the function body from the original module. The extracted body is then compiled and executed.
Definition at line 61 of file CompileOnDemandLayer.h.
| typedef std::function<std::unique_ptr<IndirectStubsMgrT>)> llvm::orc::CompileOnDemandLayer< BaseLayerT, CompileCallbackMgrT, IndirectStubsMgrT >::IndirectStubsManagerBuilderT |
Builder for IndirectStubsManagers.
Definition at line 195 of file CompileOnDemandLayer.h.
| typedef LogicalDylibList::iterator llvm::orc::CompileOnDemandLayer< BaseLayerT, CompileCallbackMgrT, IndirectStubsMgrT >::ModuleSetHandleT |
Handle to a set of loaded modules.
Definition at line 188 of file CompileOnDemandLayer.h.
| typedef std::function<std::set<Function*>Function&)> llvm::orc::CompileOnDemandLayer< BaseLayerT, CompileCallbackMgrT, IndirectStubsMgrT >::PartitioningFtor |
Module partitioning functor.
Definition at line 191 of file CompileOnDemandLayer.h.
|
inline |
Construct a compile-on-demand layer instance.
Definition at line 198 of file CompileOnDemandLayer.h.
|
inline |
Add a module to the compile-on-demand layer.
Definition at line 210 of file CompileOnDemandLayer.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 249 of file CompileOnDemandLayer.h.
|
inline |
Get the address of a symbol provided by this layer, or some layer below this one.
Definition at line 262 of file CompileOnDemandLayer.h.
Referenced by llvm::orc::CompileOnDemandLayer< CompileLayerT, CompileCallbackMgr >::findSymbol().
|
inline |
Remove the module represented by the given handle.
This will remove all modules in the layers below that were derived from the module represented by H.
Definition at line 241 of file CompileOnDemandLayer.h.
|
inline |
Update the stub for the given function to point at FnBodyAddr.
This can be used to support re-optimization.
Definition at line 276 of file CompileOnDemandLayer.h.
1.8.6