[llvm] r274270 - [CMake] Module builds depend on target intrinsics_gen to be built first.
Vassil Vassilev via llvm-commits
llvm-commits at lists.llvm.org
Tue Jul 18 06:18:00 PDT 2017
On 18/07/17 15:07, NAKAMURA Takumi wrote:
> I suppose there'd be no issue in trunk's modulemap as far as I
> investigated. Could we revert it?
We maybe stopped seeing it because of the current order of includes
which trigger the implicit module builds. This mostly used to happen if
we have a header dependency on content of module LLVM_intrinsic_gen. If
we want to revert this we probably need to impose more restrictions on
the way we trigger implicit module builds.
OTOH this adds an extra dependency which might be a build bottleneck. If
you opt to revert it please keep in mind the issue could reappear.
>
> On Fri, Jul 1, 2016 at 5:42 AM Vassil Vassilev via llvm-commits
> <llvm-commits at lists.llvm.org <mailto:llvm-commits at lists.llvm.org>> wrote:
>
> Author: vvassilev
> Date: Thu Jun 30 15:35:56 2016
> New Revision: 274270
>
> URL: http://llvm.org/viewvc/llvm-project?rev=274270&view=rev
> Log:
> [CMake] Module builds depend on target intrinsics_gen to be built
> first.
>
> When compiling with modules, header A and B can be in the same
> module M.
> B depends on intrinsics_gen and A doesn't. Compiling a source file
> #include-ing
> header A, we implicitly request module M to be built. It puts
> header A and B in
> the same TU and tries to build them. Since B depends on
> intrinsics_gen (which
> might not be built yet) we run into build failures.
>
> This should fix our modules buildbot.
>
> Patch reviewed by Chris Bieneman.
>
> Modified:
> llvm/trunk/CMakeLists.txt
>
> Modified: llvm/trunk/CMakeLists.txt
> URL:
> http://llvm.org/viewvc/llvm-project/llvm/trunk/CMakeLists.txt?rev=274270&r1=274269&r2=274270&view=diff
> ==============================================================================
> --- llvm/trunk/CMakeLists.txt (original)
> +++ llvm/trunk/CMakeLists.txt Thu Jun 30 15:35:56 2016
> @@ -700,6 +700,15 @@ add_subdirectory(lib/TableGen)
>
> add_subdirectory(utils/TableGen)
>
> +# Force target to be built as soon as possible. Clang modules
> builds depend
> +# header-wise on it as they ship all headers from the umbrella
> folders. Building
> +# an entire module might include header, which depends on
> intrinsics_gen. This
> +# should be right after LLVMSupport and LLVMTableGen otherwise we
> introduce a
> +# circular dependence.
> +if (LLVM_ENABLE_MODULES)
> + list(APPEND LLVM_COMMON_DEPENDS intrinsics_gen)
> +endif(LLVM_ENABLE_MODULES)
> +
> add_subdirectory(include/llvm)
>
> add_subdirectory(lib)
>
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at lists.llvm.org <mailto:llvm-commits at lists.llvm.org>
> http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170718/cbf4765a/attachment.html>
More information about the llvm-commits
mailing list