sun::driver::SourceRegistration

sun::driver::SourceRegistration

class · Source (opens in a new tab)

class sun::driver::SourceRegistration : public llvm::orc::ObjectLinkingLayer::Plugin

Tracks source indexes alongside JIT resources, including unload and transfer.

Inherits

  • llvm::orc::ObjectLinkingLayer::Plugin (public)

Public Functions

SourceRegistration

public · function · Source (opens in a new tab)

sun::driver::SourceRegistration::SourceRegistration(std::shared_ptr< ExceptionSourceCallbacks > callbacks)

Retains callbacks for the particular JIT runtime instance.

Related: ExceptionSourceCallbacks

modifyPassConfig

public · function · Source (opens in a new tab)

void sun::driver::SourceRegistration::modifyPassConfig(llvm::orc::MaterializationResponsibility &responsibility, llvm::jitlink::LinkGraph &graph, llvm::jitlink::PassConfiguration &config) override

Waits for relocations before registering function addresses and source data.

notifyEmitted

public · function · Source (opens in a new tab)

llvm::Error sun::driver::SourceRegistration::notifyEmitted(llvm::orc::MaterializationResponsibility &responsibility) override

Publishes indexes only after target memory has been finalized.

notifyFailed

public · function · Source (opens in a new tab)

llvm::Error sun::driver::SourceRegistration::notifyFailed(llvm::orc::MaterializationResponsibility &responsibility) override

Removes any indexes whose materialization failed.

notifyRemovingResources

public · function · Source (opens in a new tab)

llvm::Error sun::driver::SourceRegistration::notifyRemovingResources(llvm::orc::JITDylib &, llvm::orc::ResourceKey key) override

Unregisters indexes before their backing JIT allocations disappear.

notifyTransferringResources

public · function · Source (opens in a new tab)

void sun::driver::SourceRegistration::notifyTransferringResources(llvm::orc::JITDylib &, llvm::orc::ResourceKey destination, llvm::orc::ResourceKey source) override

Preserves ownership when LLVM transfers code between resource trackers.

Private Fields

callbacks_

private · variable · Source (opens in a new tab)

std::shared_ptr<ExceptionSourceCallbacks> sun::driver::SourceRegistration::callbacks_

No documentation comment.

Related: ExceptionSourceCallbacks

maps_

private · variable · Source (opens in a new tab)

std::map<llvm::orc::ResourceKey, std::vector<void*> > sun::driver::SourceRegistration::maps_

No documentation comment.

mutex_

private · variable · Source (opens in a new tab)

std::mutex sun::driver::SourceRegistration::mutex_

No documentation comment.