LLVM: lib/ExecutionEngine/Orc/EPCGenericDylibManager.cpp Source File (original) (raw)

1

2

3

4

5

6

7

8

10

14

15namespace llvm {

16namespace orc {

18

19template <>

34

35template <>

41

42template <>

45 using MemberSerialization =

47

48public:

52

58};

59

60}

61

66 if (auto Err = EPC.getBootstrapSymbols(

67 {{SAs.Instance, rt::SimpleExecutorDylibManagerInstanceName},

68 {SAs.Open, rt::SimpleExecutorDylibManagerOpenWrapperName},

69 {SAs.Resolve, rt::SimpleExecutorDylibManagerResolveWrapperName}}))

70 return std::move(Err);

72}

73

77 if (auto Err =

79 SAs.Open, H, SAs.Instance, Path, Mode))

80 return std::move(Err);

81 return H;

82}

83

88 SAs.Resolve,

89 [Complete = std::move(Complete)](

90 Error SerializationErr,

93 if (SerializationErr) {

95 Complete(std::move(SerializationErr));

96 return;

97 }

98 Complete(std::move(Result));

99 },

101}

102

107 SAs.Resolve,

108 [Complete = std::move(Complete)](

109 Error SerializationErr,

112 if (SerializationErr) {

114 Complete(std::move(SerializationErr));

115 return;

116 }

117 Complete(std::move(Result));

118 },

120}

121

122}

123}

static cl::opt< RegAllocEvictionAdvisorAnalysisLegacy::AdvisorMode > Mode("regalloc-enable-advisor", cl::Hidden, cl::init(RegAllocEvictionAdvisorAnalysisLegacy::AdvisorMode::Default), cl::desc("Enable regalloc advisor mode"), cl::values(clEnumValN(RegAllocEvictionAdvisorAnalysisLegacy::AdvisorMode::Default, "default", "Default"), clEnumValN(RegAllocEvictionAdvisorAnalysisLegacy::AdvisorMode::Release, "release", "precompiled"), clEnumValN(RegAllocEvictionAdvisorAnalysisLegacy::AdvisorMode::Development, "development", "for training")))

static int Lookup(ArrayRef< TableEntry > Table, unsigned Opcode)

Lightweight error class with error context and mandatory checking.

Tagged union holding either a T or a Error.

StringRef - Represent a constant reference to a string, i.e.

static LLVM_ABI Expected< EPCGenericDylibManager > CreateWithDefaultBootstrapSymbols(ExecutorProcessControl &EPC)

Create an EPCGenericMemoryAccess instance from a given set of function addrs.

Definition EPCGenericDylibManager.cpp:63

LLVM_ABI void lookupAsync(tpctypes::DylibHandle H, const SymbolLookupSet &Lookup, SymbolLookupCompleteFn Complete)

Looks up symbols within the given dylib.

Definition EPCGenericDylibManager.cpp:84

LLVM_ABI Expected< tpctypes::DylibHandle > open(StringRef Path, uint64_t Mode)

Loads the dylib with the given name.

Definition EPCGenericDylibManager.cpp:74

unique_function< void(Expected< tpctypes::LookupResult >)> SymbolLookupCompleteFn

Represents an address in the executor process.

ExecutorProcessControl supports interaction with a JIT target process.

A set of symbols to look up, each associated with a SymbolLookupFlags value.

std::pair< SymbolStringPtr, SymbolLookupFlags > value_type

shared::SPSExpected< shared::SPSExecutorAddr >(shared::SPSExecutorAddr, shared::SPSString, uint64_t) SPSSimpleExecutorDylibManagerOpenSignature

shared::SPSExpected< shared::SPSSequence< shared::SPSOptional< shared::SPSExecutorSymbolDef > > >( shared::SPSExecutorAddr, shared::SPSRemoteSymbolLookupSet) SPSSimpleExecutorDylibManagerResolveSignature

ExecutorAddr DylibHandle

A handle used to represent a loaded dylib in the target process.

std::vector< RemoteSymbolLookupSetElement > RemoteSymbolLookupSet

This is an optimization pass for GlobalISel generic memory operations.

void cantFail(Error Err, const char *Msg=nullptr)

Report a fatal error if Err is a failure value.

A pair of a dylib and a set of symbols to be looked up.

tpctypes::DylibHandle Handle

const SymbolLookupSet & Symbols

Function addresses for memory access.