[clang] [llvm] [clang] Support multiple in-process cc1 jobs in a ToolSession (PR #222531)
Reid Kleckner via cfe-commits
cfe-commits at lists.llvm.org
Fri Sep 18 16:51:46 PDT 2026
================
@@ -387,6 +388,12 @@ int Command::Execute(ArrayRef<std::optional<StringRef>> Redirects,
ErrMsg, ExecutionFailed, &ProcStat);
}
+void Command::enableFree() {
+ llvm::erase_if(Arguments, [](const char *Arg) {
+ return StringRef(Arg) == "-disable-free";
----------------
rnk wrote:
Can you find a way to make the command correct by construction, rather than building the command one way and filtering out the thing we don't want? We already through through a "for diagnostics" flag.
Worst case, if we mark which commands support disable free, we can move the addition of disable free to the CC1Command class (here) instead of the Clang toolchain logic.
https://github.com/llvm/llvm-project/pull/222531
More information about the cfe-commits
mailing list