ychen created this revision. ychen added a reviewer: aganea. Herald added a project: clang. Herald added a subscriber: cfe-commits. ychen planned changes to this revision. ychen added a comment.
This may not be complete. For D74490 <https://reviews.llvm.org/D74490>. For cases like where external assembler is used, counting the job number is not exactly right. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D80454 Files: clang/lib/Driver/Driver.cpp Index: clang/lib/Driver/Driver.cpp =================================================================== --- clang/lib/Driver/Driver.cpp +++ clang/lib/Driver/Driver.cpp @@ -3763,7 +3763,8 @@ } // If we have more than one job, then disable integrated-cc1 for now. - if (C.getJobs().size() > 1) + if (std::count_if(C.getActions().begin(), C.getActions().end(), + [](Action *A) { return isa<CompileJobAction>(A); }) > 1) for (auto &J : C.getJobs()) J.InProcess = false;
Index: clang/lib/Driver/Driver.cpp =================================================================== --- clang/lib/Driver/Driver.cpp +++ clang/lib/Driver/Driver.cpp @@ -3763,7 +3763,8 @@ } // If we have more than one job, then disable integrated-cc1 for now. - if (C.getJobs().size() > 1) + if (std::count_if(C.getActions().begin(), C.getActions().end(), + [](Action *A) { return isa<CompileJobAction>(A); }) > 1) for (auto &J : C.getJobs()) J.InProcess = false;
_______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits