================
@@ -460,10 +464,99 @@ const char *const Runtimes = R"(
   EXTERN_C void __clang_Interpreter_SetValueNoAlloc(void *This, void *OutVal, 
void *OpaqueType, ...);
 )";
 
+llvm::ExitOnError ExitOnErr;
+
+std::unique_ptr<llvm::orc::LLJITBuilder>
+Interpreter::outOfProcessJITBuilder(OutOfProcessJITConfig OutOfProcessConfig) {
+  std::unique_ptr<llvm::orc::ExecutorProcessControl> EPC;
+  if (OutOfProcessConfig.OOPExecutor != "") {
+    // Launch an out-of-process executor locally in a child process.
+    EPC = ExitOnErr(launchExecutor(OutOfProcessConfig.OOPExecutor,
----------------
vgvassilev wrote:

Remember this is the library, it must not abort the process. Instead the 
interface should return 
`llvm::Expected<std::unique_ptr<llvm::orc::LLJITBuilder>>` and propagate the 
error up.

https://github.com/llvm/llvm-project/pull/155140
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to