mirror of
https://github.com/RPCSX/llvm.git
synced 2024-11-30 23:20:54 +00:00
[Orc] Tidy up initialization based on review feedback for r239561 from dblaikie.
NFC. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@239645 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
1849093f7b
commit
69fb65b52e
@ -88,26 +88,25 @@ public:
|
||||
// 1) Search the JIT symbols.
|
||||
// 2) Check for C++ runtime overrides.
|
||||
// 3) Search the host process (LLI)'s symbol table.
|
||||
auto Resolver =
|
||||
std::shared_ptr<RuntimeDyld::SymbolResolver>(
|
||||
orc::createLambdaResolver(
|
||||
[this](const std::string &Name) {
|
||||
if (auto Sym = CODLayer.findSymbol(Name, true))
|
||||
return RuntimeDyld::SymbolInfo(Sym.getAddress(),
|
||||
Sym.getFlags());
|
||||
if (auto Sym = CXXRuntimeOverrides.searchOverrides(Name))
|
||||
return Sym;
|
||||
std::shared_ptr<RuntimeDyld::SymbolResolver> Resolver =
|
||||
orc::createLambdaResolver(
|
||||
[this](const std::string &Name) {
|
||||
if (auto Sym = CODLayer.findSymbol(Name, true))
|
||||
return RuntimeDyld::SymbolInfo(Sym.getAddress(),
|
||||
Sym.getFlags());
|
||||
if (auto Sym = CXXRuntimeOverrides.searchOverrides(Name))
|
||||
return Sym;
|
||||
|
||||
if (auto Addr =
|
||||
RTDyldMemoryManager::getSymbolAddressInProcess(Name))
|
||||
return RuntimeDyld::SymbolInfo(Addr, JITSymbolFlags::Exported);
|
||||
if (auto Addr =
|
||||
RTDyldMemoryManager::getSymbolAddressInProcess(Name))
|
||||
return RuntimeDyld::SymbolInfo(Addr, JITSymbolFlags::Exported);
|
||||
|
||||
return RuntimeDyld::SymbolInfo(nullptr);
|
||||
},
|
||||
[](const std::string &Name) {
|
||||
return RuntimeDyld::SymbolInfo(nullptr);
|
||||
}
|
||||
));
|
||||
return RuntimeDyld::SymbolInfo(nullptr);
|
||||
},
|
||||
[](const std::string &Name) {
|
||||
return RuntimeDyld::SymbolInfo(nullptr);
|
||||
}
|
||||
);
|
||||
|
||||
// Add the module to the JIT.
|
||||
std::vector<std::unique_ptr<Module>> S;
|
||||
|
Loading…
Reference in New Issue
Block a user