LLVM  17.0.0git
Classes | Public Types | Public Member Functions | Protected Types | Protected Member Functions | List of all members
llvm::orc::LazyCallThroughManager Class Reference

Manages a set of 'lazy call-through' trampolines. More...

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

Inheritance diagram for llvm::orc::LazyCallThroughManager:
Inheritance graph


struct  ReexportsEntry

Public Types

using NotifyResolvedFunction = unique_function< Error(JITTargetAddress ResolvedAddr)>

Public Member Functions

 LazyCallThroughManager (ExecutionSession &ES, JITTargetAddress ErrorHandlerAddr, TrampolinePool *TP)
Expected< JITTargetAddressgetCallThroughTrampoline (JITDylib &SourceJD, SymbolStringPtr SymbolName, NotifyResolvedFunction NotifyResolved)
void resolveTrampolineLandingAddress (JITTargetAddress TrampolineAddr, TrampolinePool::NotifyLandingResolvedFunction NotifyLandingResolved)
virtual ~LazyCallThroughManager ()=default

Protected Types

using NotifyLandingResolvedFunction = TrampolinePool::NotifyLandingResolvedFunction

Protected Member Functions

JITTargetAddress reportCallThroughError (Error Err)
Expected< ReexportsEntryfindReexport (JITTargetAddress TrampolineAddr)
Error notifyResolved (JITTargetAddress TrampolineAddr, JITTargetAddress ResolvedAddr)
void setTrampolinePool (TrampolinePool &TP)

Detailed Description

Manages a set of 'lazy call-through' trampolines.

These are compiler re-entry trampolines that are pre-bound to look up a given symbol in a given JITDylib, then jump to that address. Since compilation of symbols is triggered on first lookup, these call-through trampolines can be used to implement lazy compilation.

The easiest way to construct these call-throughs is using the lazyReexport function.

Definition at line 38 of file LazyReexports.h.

Member Typedef Documentation

◆ NotifyLandingResolvedFunction

Definition at line 60 of file LazyReexports.h.

◆ NotifyResolvedFunction

Definition at line 41 of file LazyReexports.h.

Constructor & Destructor Documentation

◆ LazyCallThroughManager()

llvm::orc::LazyCallThroughManager::LazyCallThroughManager ( ExecutionSession ES,
JITTargetAddress  ErrorHandlerAddr,
TrampolinePool TP 

Definition at line 19 of file LazyReexports.cpp.

◆ ~LazyCallThroughManager()

virtual llvm::orc::LazyCallThroughManager::~LazyCallThroughManager ( )

Member Function Documentation

◆ findReexport()

Expected< LazyCallThroughManager::ReexportsEntry > llvm::orc::LazyCallThroughManager::findReexport ( JITTargetAddress  TrampolineAddr)

Definition at line 45 of file LazyReexports.cpp.

References llvm::createStringError(), I, and llvm::inconvertibleErrorCode().

◆ getCallThroughTrampoline()

Expected< JITTargetAddress > llvm::orc::LazyCallThroughManager::getCallThroughTrampoline ( JITDylib SourceJD,
SymbolStringPtr  SymbolName,
NotifyResolvedFunction  NotifyResolved 

◆ notifyResolved()

Error llvm::orc::LazyCallThroughManager::notifyResolved ( JITTargetAddress  TrampolineAddr,
JITTargetAddress  ResolvedAddr 

Definition at line 55 of file LazyReexports.cpp.

References I, move, and llvm::Error::success().

◆ reportCallThroughError()

JITTargetAddress llvm::orc::LazyCallThroughManager::reportCallThroughError ( Error  Err)

Definition at line 39 of file LazyReexports.cpp.

◆ resolveTrampolineLandingAddress()

void llvm::orc::LazyCallThroughManager::resolveTrampolineLandingAddress ( JITTargetAddress  TrampolineAddr,
TrampolinePool::NotifyLandingResolvedFunction  NotifyLandingResolved 

Definition at line 70 of file LazyReexports.cpp.

◆ setTrampolinePool()

void llvm::orc::LazyCallThroughManager::setTrampolinePool ( TrampolinePool TP)

Definition at line 71 of file LazyReexports.h.

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