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

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

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

Classes

class  SpeculateTask

Public Types

using RecordExecutionFunction
Public Types inherited from llvm::orc::LazyReexportsManager::Listener
using CallThroughInfo = LazyReexportsManager::CallThroughInfo

Public Member Functions

 SimpleLazyReexportsSpeculator (SimpleLazyReexportsSpeculator &&)=delete
SimpleLazyReexportsSpeculatoroperator= (SimpleLazyReexportsSpeculator &&)=delete
 ~SimpleLazyReexportsSpeculator () override
void onLazyReexportsCreated (JITDylib &JD, ResourceKey K, const SymbolAliasMap &Reexports) override
 Called under the session lock when new lazy reexports are created.
void onLazyReexportsTransfered (JITDylib &JD, ResourceKey DstK, ResourceKey SrcK) override
 Called under the session lock when lazy reexports have their ownership transferred to a new ResourceKey.
Error onLazyReexportsRemoved (JITDylib &JD, ResourceKey K) override
 Called under the session lock when lazy reexports are removed.
void onLazyReexportCalled (const CallThroughInfo &CTI) override
 Called outside the session lock when a lazy reexport is called.
void addSpeculationSuggestions (std::vector< std::pair< std::string, SymbolStringPtr > > NewSuggestions)
Public Member Functions inherited from llvm::orc::LazyReexportsManager::Listener
virtual ~Listener ()

Static Public Member Functions

static std::shared_ptr< SimpleLazyReexportsSpeculatorCreate (ExecutionSession &ES, RecordExecutionFunction RecordExec={})

Detailed Description

Definition at line 274 of file LazyReexports.h.

Member Typedef Documentation

◆ RecordExecutionFunction

Initial value:
unique_function<void(const CallThroughInfo &CTI)>
LazyReexportsManager::CallThroughInfo CallThroughInfo
unique_function is a type-erasing functor similar to std::function.

Definition at line 277 of file LazyReexports.h.

Constructor & Destructor Documentation

◆ SimpleLazyReexportsSpeculator()

llvm::orc::SimpleLazyReexportsSpeculator::SimpleLazyReexportsSpeculator ( SimpleLazyReexportsSpeculator && )
delete

◆ ~SimpleLazyReexportsSpeculator()

llvm::orc::SimpleLazyReexportsSpeculator::~SimpleLazyReexportsSpeculator ( )
override

Definition at line 467 of file LazyReexports.cpp.

References _, and ~SimpleLazyReexportsSpeculator().

Referenced by ~SimpleLazyReexportsSpeculator().

Member Function Documentation

◆ addSpeculationSuggestions()

void llvm::orc::SimpleLazyReexportsSpeculator::addSpeculationSuggestions ( std::vector< std::pair< std::string, SymbolStringPtr > > NewSuggestions)

Definition at line 535 of file LazyReexports.cpp.

References addSpeculationSuggestions().

Referenced by addSpeculationSuggestions(), and operator=().

◆ Create()

std::shared_ptr< SimpleLazyReexportsSpeculator > llvm::orc::SimpleLazyReexportsSpeculator::Create ( ExecutionSession & ES,
RecordExecutionFunction RecordExec = {} )
inlinestatic

Definition at line 281 of file LazyReexports.h.

◆ onLazyReexportCalled()

void llvm::orc::SimpleLazyReexportsSpeculator::onLazyReexportCalled ( const CallThroughInfo & CTI)
overridevirtual

Called outside the session lock when a lazy reexport is called.

NOTE: Since this is called outside the session lock there is a chance that the reexport referred to has already been removed. Listeners must be prepared to handle requests for stale reexports.

Implements llvm::orc::LazyReexportsManager::Listener.

Definition at line 529 of file LazyReexports.cpp.

References onLazyReexportCalled().

Referenced by onLazyReexportCalled(), and operator=().

◆ onLazyReexportsCreated()

void llvm::orc::SimpleLazyReexportsSpeculator::onLazyReexportsCreated ( JITDylib & JD,
ResourceKey K,
const SymbolAliasMap & Reexports )
overridevirtual

Called under the session lock when new lazy reexports are created.

Implements llvm::orc::LazyReexportsManager::Listener.

Definition at line 472 of file LazyReexports.cpp.

References onLazyReexportsCreated(), and llvm::ThreadSafeRefCountedBase< Derived >::Retain().

Referenced by onLazyReexportsCreated(), and operator=().

◆ onLazyReexportsRemoved()

Error llvm::orc::SimpleLazyReexportsSpeculator::onLazyReexportsRemoved ( JITDylib & JD,
ResourceKey K )
overridevirtual

Called under the session lock when lazy reexports are removed.

Implements llvm::orc::LazyReexportsManager::Listener.

Definition at line 511 of file LazyReexports.cpp.

References I, onLazyReexportsRemoved(), llvm::ThreadSafeRefCountedBase< Derived >::Release(), and llvm::Error::success().

Referenced by onLazyReexportsRemoved(), and operator=().

◆ onLazyReexportsTransfered()

void llvm::orc::SimpleLazyReexportsSpeculator::onLazyReexportsTransfered ( JITDylib & JD,
ResourceKey DstK,
ResourceKey SrcK )
overridevirtual

Called under the session lock when lazy reexports have their ownership transferred to a new ResourceKey.

Implements llvm::orc::LazyReexportsManager::Listener.

Definition at line 485 of file LazyReexports.cpp.

References llvm::append_range(), I, and onLazyReexportsTransfered().

Referenced by onLazyReexportsTransfered(), and operator=().

◆ operator=()


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