[ORC] Rename MaterializationResponsibility::delegate to replace and add a new
delegate method (and unit test).
The name 'replace' better captures what the old delegate method did: it
returned materialization responsibility for a set of symbols to the VSO.
The new delegate method delegates responsibility for a set of symbols to a new
MaterializationResponsibility instance. This can be used to split responsibility
between multiple threads, or multiple materialization methods.
llvm-svn: 336603
diff --git a/llvm/lib/ExecutionEngine/Orc/CompileOnDemandLayer.cpp b/llvm/lib/ExecutionEngine/Orc/CompileOnDemandLayer.cpp
index e8d24f9..ebd8d43 100644
--- a/llvm/lib/ExecutionEngine/Orc/CompileOnDemandLayer.cpp
+++ b/llvm/lib/ExecutionEngine/Orc/CompileOnDemandLayer.cpp
@@ -68,7 +68,7 @@
}
}
- R.delegate(symbolAliases(std::move(Aliases)));
+ R.replace(symbolAliases(std::move(Aliases)));
}
static std::unique_ptr<Module>
@@ -199,7 +199,7 @@
DelegatedSymbolToDefinition.size() &&
"SymbolFlags and SymbolToDefinition should have the same number "
"of entries");
- R.delegate(llvm::make_unique<ExtractingIRMaterializationUnit>(
+ R.replace(llvm::make_unique<ExtractingIRMaterializationUnit>(
std::move(M), std::move(DelegatedSymbolFlags),
std::move(DelegatedSymbolToDefinition), Parent, BackingResolver));
}