LLVM 22.0.0git
llvm::orc::CompileOnDemandLayer Class Reference

#include "llvm/ExecutionEngine/Orc/CompileOnDemandLayer.h"

Inheritance diagram for llvm::orc::CompileOnDemandLayer:
[legend]

Public Types

using IndirectStubsManagerBuilder
 Builder for IndirectStubsManagers.

Public Member Functions

 CompileOnDemandLayer (ExecutionSession &ES, IRLayer &BaseLayer, LazyCallThroughManager &LCTMgr, IndirectStubsManagerBuilder BuildIndirectStubsManager)
 Construct a CompileOnDemandLayer.
void setImplMap (ImplSymbolMap *Imp)
 Sets the ImplSymbolMap.
void emit (std::unique_ptr< MaterializationResponsibility > R, ThreadSafeModule TSM) override
 Emits the given module.
Public Member Functions inherited from llvm::orc::IRLayer
 IRLayer (ExecutionSession &ES, const IRSymbolMapper::ManglingOptions *&MO)
virtual ~IRLayer ()
ExecutionSessiongetExecutionSession ()
 Returns the ExecutionSession for this layer.
const IRSymbolMapper::ManglingOptions *& getManglingOptions () const
 Get the mangling options for this layer.
void setCloneToNewContextOnEmit (bool CloneToNewContextOnEmit)
 Sets the CloneToNewContextOnEmit flag (false by default).
bool getCloneToNewContextOnEmit () const
 Returns the current value of the CloneToNewContextOnEmit flag.
virtual Error add (ResourceTrackerSP RT, ThreadSafeModule TSM)
 Add a MaterializatinoUnit representing the given IR to the JITDylib targeted by the given tracker.
Error add (JITDylib &JD, ThreadSafeModule TSM)
 Adds a MaterializationUnit representing the given IR to the given JITDylib.

Detailed Description

Definition at line 56 of file CompileOnDemandLayer.h.

Member Typedef Documentation

◆ IndirectStubsManagerBuilder

Initial value:
std::function<std::unique_ptr<IndirectStubsManager>()>

Builder for IndirectStubsManagers.

Definition at line 59 of file CompileOnDemandLayer.h.

Constructor & Destructor Documentation

◆ CompileOnDemandLayer()

CompileOnDemandLayer::CompileOnDemandLayer ( ExecutionSession & ES,
IRLayer & BaseLayer,
LazyCallThroughManager & LCTMgr,
IndirectStubsManagerBuilder BuildIndirectStubsManager )

Member Function Documentation

◆ emit()

void CompileOnDemandLayer::emit ( std::unique_ptr< MaterializationResponsibility > R,
ThreadSafeModule TSM )
overridevirtual

Emits the given module.

This should not be called by clients: it will be called by the JIT when a definition added via the add method is requested.

Implements llvm::orc::IRLayer.

Definition at line 27 of file CompileOnDemandLayer.cpp.

References assert(), llvm::DenseMapBase< DerivedT, KeyT, ValueT, KeyInfoT, BucketT >::empty(), llvm::orc::IRLayer::getExecutionSession(), llvm::orc::IRLayer::getManglingOptions(), llvm::orc::lazyReexports(), llvm::orc::MatchAllSymbols, llvm::orc::reexports(), and llvm::orc::ExecutionSession::reportError().

◆ setImplMap()

void CompileOnDemandLayer::setImplMap ( ImplSymbolMap * Imp)

Sets the ImplSymbolMap.

Definition at line 23 of file CompileOnDemandLayer.cpp.


The documentation for this class was generated from the following files: