Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update FreeBSD toolchain on dist images #72390

Closed
nikic opened this issue May 20, 2020 · 0 comments · Fixed by #75204
Closed

Update FreeBSD toolchain on dist images #72390

nikic opened this issue May 20, 2020 · 0 comments · Fixed by #75204
Labels
A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. O-freebsd Operating system: FreeBSD T-infra Relevant to the infrastructure team, which will review and decide on the PR/issue.

Comments

@nikic
Copy link
Contributor

nikic commented May 20, 2020

During the LLVM 10 update in #67759 we ran into an LLVM build failure on FreeBSD:

In file included from /checkout/src/llvm-project/llvm/tools/llvm-profdata/llvm-profdata.cpp:13:
In file included from /checkout/src/llvm-project/llvm/include/llvm/ADT/SmallSet.h:17:
In file included from /checkout/src/llvm-project/llvm/include/llvm/ADT/SmallPtrSet.h:20:
In file included from /checkout/src/llvm-project/llvm/include/llvm/Support/type_traits.h:18:
/usr/local/x86_64-unknown-freebsd10/usr/include/c++/v1/utility:283:11: error: call to deleted constructor of 'llvm::Error'
        : first(__p.first),
          ^     ~~~~~~~~~
/usr/local/x86_64-unknown-freebsd10/usr/include/c++/v1/memory:1645:31: note: in instantiation of member function 'std::__1::pair<llvm::Error, std::__1::basic_string<char> >::pair' requested here
            ::new((void*)__p) _Up(_VSTD::forward<_Args>(__args)...);
                              ^
/usr/local/x86_64-unknown-freebsd10/usr/include/c++/v1/memory:1572:18: note: in instantiation of function template specialization 'std::__1::allocator<std::__1::pair<llvm::Error, std::__1::basic_string<char> > >::construct<std::__1::pair<llvm::Error, std::__1::basic_string<char> >, const std::__1::pair<llvm::Error, std::__1::basic_string<char> > &>' requested here
            {__a.construct(__p, _VSTD::forward<_Args>(__args)...);}
                 ^
/usr/local/x86_64-unknown-freebsd10/usr/include/c++/v1/memory:1453:14: note: in instantiation of function template specialization 'std::__1::allocator_traits<std::__1::allocator<std::__1::pair<llvm::Error, std::__1::basic_string<char> > > >::__construct<std::__1::pair<llvm::Error, std::__1::basic_string<char> >, const std::__1::pair<llvm::Error, std::__1::basic_string<char> > &>' requested here
            {__construct(__has_construct<allocator_type, _Tp*, _Args...>(),
             ^
/usr/local/x86_64-unknown-freebsd10/usr/include/c++/v1/memory:1535:17: note: in instantiation of function template specialization 'std::__1::allocator_traits<std::__1::allocator<std::__1::pair<llvm::Error, std::__1::basic_string<char> > > >::construct<std::__1::pair<llvm::Error, std::__1::basic_string<char> >, const std::__1::pair<llvm::Error, std::__1::basic_string<char> > &>' requested here
                construct(__a, _VSTD::__to_raw_pointer(__end2-1), _VSTD::move_if_noexcept(*--__end1));
                ^
/usr/local/x86_64-unknown-freebsd10/usr/include/c++/v1/vector:897:21: note: in instantiation of function template specialization 'std::__1::allocator_traits<std::__1::allocator<std::__1::pair<llvm::Error, std::__1::basic_string<char> > > >::__construct_backward<std::__1::pair<llvm::Error, std::__1::basic_string<char> > *>' requested here
    __alloc_traits::__construct_backward(this->__alloc(), this->__begin_, this->__end_, __v.__begin_);
                    ^
/usr/local/x86_64-unknown-freebsd10/usr/include/c++/v1/vector:1635:5: note: in instantiation of member function 'std::__1::vector<std::__1::pair<llvm::Error, std::__1::basic_string<char> >, std::__1::allocator<std::__1::pair<llvm::Error, std::__1::basic_string<char> > > >::__swap_out_circular_buffer' requested here
    __swap_out_circular_buffer(__v);
    ^
/usr/local/x86_64-unknown-freebsd10/usr/include/c++/v1/vector:1654:9: note: in instantiation of function template specialization 'std::__1::vector<std::__1::pair<llvm::Error, std::__1::basic_string<char> >, std::__1::allocator<std::__1::pair<llvm::Error, std::__1::basic_string<char> > > >::__emplace_back_slow_path<llvm::Error, const std::__1::basic_string<char> &>' requested here
        __emplace_back_slow_path(_VSTD::forward<_Args>(__args)...);
        ^
/checkout/src/llvm-project/llvm/tools/llvm-profdata/llvm-profdata.cpp:209:18: note: in instantiation of function template specialization 'std::__1::vector<std::__1::pair<llvm::Error, std::__1::basic_string<char> >, std::__1::allocator<std::__1::pair<llvm::Error, std::__1::basic_string<char> > > >::emplace_back<llvm::Error, const std::__1::basic_string<char> &>' requested here
      WC->Errors.emplace_back(make_error<InstrProfError>(IPE), TestFilename);
                 ^
/checkout/src/llvm-project/llvm/include/llvm/Support/Error.h:186:3: note: 'Error' has been explicitly marked deleted here
  Error(const Error &Other) = delete;
  ^
1 error generated.
make[2]: *** [tools/llvm-profdata/CMakeFiles/llvm-profdata.dir/llvm-profdata.cpp.o] Error 1
make[1]: *** [tools/llvm-profdata/CMakeFiles/llvm-profdata.dir/all] Error 2

This seems to be related to a too old version of libc++.

We work around this with a patch to our LLVM fork in rust-lang/llvm-project@943dbdd.

While we have avoided this particular issue, we still need to update the used FreeBSD version (or possibly just libc++?) to avoid additional problems in the future. The relevant code seems to be: https://github.com/rust-lang/rust/blob/master/src/ci/docker/scripts/freebsd-toolchain.sh.

@nikic nikic added the O-freebsd Operating system: FreeBSD label May 20, 2020
@nikic nikic mentioned this issue May 20, 2020
8 tasks
@jonas-schievink jonas-schievink added A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. T-infra Relevant to the infrastructure team, which will review and decide on the PR/issue. labels May 20, 2020
@bors bors closed this as completed in 13290e8 Aug 10, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. O-freebsd Operating system: FreeBSD T-infra Relevant to the infrastructure team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants