[llvm] [llvm][Support] Add support for executing a detached process (PR #81708)
Michael Spencer via llvm-commits
llvm-commits at lists.llvm.org
Wed Feb 14 12:39:01 PST 2024
================
@@ -284,6 +285,8 @@ static bool Execute(ProcessInfo &PI, StringRef Program,
unsigned CreateFlags = CREATE_UNICODE_ENVIRONMENT;
if (AffinityMask)
CreateFlags |= CREATE_SUSPENDED;
+ if (DetachProcess)
+ CreateFlags |= DETACHED_PROCESS;
----------------
Bigcheese wrote:
We discussed using `ShellExecute`, but it still gives you a console. The goal here is to not have a console at all. `DETACHED_PROCESS` gives the correct semantics for a daemon spawned by any given `clang` instance that doesn't belong to any specific instance.
https://github.com/llvm/llvm-project/pull/81708
More information about the llvm-commits
mailing list