Subject: [Boost-bugs] [Boost C++ Libraries] #11897: Compile failure in type_traits_detail::mp_valid_impl with CUDA 7.0
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2016-01-08 14:32:58
#11897: Compile failure in type_traits_detail::mp_valid_impl with CUDA 7.0
------------------------------+-------------------------
Reporter: a.grund@⦠| Owner: johnmaddock
Type: Bugs | Status: new
Milestone: To Be Determined | Component: type_traits
Version: Boost 1.60.0 | Severity: Showstopper
Keywords: |
------------------------------+-------------------------
Including boost/thread/pthread/timespec.hpp and compiling with nvcc 7.0 in
C++11 mode throws several errors related to mp_valid_impl. This bug seems
to be a compiler bug which is fixed in CUDA 7.5 but as many HPC system
only have (and will have) 7.0 this is a real showstopper. Log output is:
{{{
/opt/pkg/devel/cuda/7.0/bin/nvcc -std=c++11 BoostMpValid.cu
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/type_traits/detail/mp_defer.hpp(33):
error: no instance of overloaded function
"boost::type_traits_detail::mp_valid_impl<F, T...>::check [with
F=boost::type_traits_detail::common_type_fold, T=<int_least64_t,
int_least64_t, intmax_t>]" matches the argument list
argument types are: (int)
detected during:
instantiation of class
"boost::type_traits_detail::mp_valid_impl<F, T...> [with
F=boost::type_traits_detail::common_type_fold, T=<int_least64_t,
int_least64_t, intmax_t>]"
(37): here
instantiation of type
"boost::type_traits_detail::mp_valid<boost::type_traits_detail::common_type_fold,
int_least64_t, int_least64_t, intmax_t>"
(50): here
instantiation of type
"boost::type_traits_detail::mp_defer<boost::type_traits_detail::common_type_fold,
int_least64_t, int_least64_t, intmax_t>"
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/type_traits/common_type.hpp(47):
here
instantiation of class "boost::common_type<T1, T2, T...> [with
T1=int_least64_t, T2=int_least64_t, T=<intmax_t>]"
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/chrono/duration.hpp(256):
here
instantiation of "ToDuration
boost::chrono::detail::duration_cast_aux<FromDuration, ToDuration, Period,
true, false>::operator()(const FromDuration &) const [with
FromDuration=boost::chrono::duration<int_least64_t, boost::nano>,
ToDuration=boost::chrono::seconds, Period=boost::ratio<1L, 1000000000L>]"
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/chrono/duration.hpp(315):
here
instantiation of "ToDuration
boost::chrono::detail::duration_cast<FromDuration,
ToDuration>::operator()(const FromDuration &) const [with
FromDuration=boost::chrono::duration<int_least64_t, boost::nano>,
ToDuration=boost::chrono::seconds]"
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/chrono/duration.hpp(789):
here
instantiation of
"boost::enable_if<boost::chrono::detail::is_duration<ToDuration>,
ToDuration>::type
boost::chrono::duration_cast<ToDuration,Rep,Period>(const
boost::chrono::duration<Rep, Period> &) [with
ToDuration=boost::chrono::seconds, Rep=int_least64_t, Period=boost::nano]"
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/thread/pthread/timespec.hpp(51):
here
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/type_traits/detail/mp_defer.hpp(50):
error: name followed by "::" must be a class or namespace name
detected during:
instantiation of type
"boost::type_traits_detail::mp_defer<boost::type_traits_detail::common_type_fold,
int_least64_t, int_least64_t, intmax_t>"
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/type_traits/common_type.hpp(47):
here
instantiation of class "boost::common_type<T1, T2, T...> [with
T1=int_least64_t, T2=int_least64_t, T=<intmax_t>]"
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/chrono/duration.hpp(256):
here
instantiation of "ToDuration
boost::chrono::detail::duration_cast_aux<FromDuration, ToDuration, Period,
true, false>::operator()(const FromDuration &) const [with
FromDuration=boost::chrono::duration<int_least64_t, boost::nano>,
ToDuration=boost::chrono::seconds, Period=boost::ratio<1L, 1000000000L>]"
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/chrono/duration.hpp(315):
here
instantiation of "ToDuration
boost::chrono::detail::duration_cast<FromDuration,
ToDuration>::operator()(const FromDuration &) const [with
FromDuration=boost::chrono::duration<int_least64_t, boost::nano>,
ToDuration=boost::chrono::seconds]"
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/chrono/duration.hpp(789):
here
instantiation of
"boost::enable_if<boost::chrono::detail::is_duration<ToDuration>,
ToDuration>::type
boost::chrono::duration_cast<ToDuration,Rep,Period>(const
boost::chrono::duration<Rep, Period> &) [with
ToDuration=boost::chrono::seconds, Rep=int_least64_t, Period=boost::nano]"
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/thread/pthread/timespec.hpp(51):
here
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/type_traits/detail/mp_defer.hpp(33):
error: no instance of overloaded function
"boost::type_traits_detail::mp_valid_impl<F, T...>::check [with
F=boost::type_traits_detail::builtin_common_type, T=<int_least64_t,
int_least64_t>]" matches the argument list
argument types are: (int)
detected during:
instantiation of class
"boost::type_traits_detail::mp_valid_impl<F, T...> [with
F=boost::type_traits_detail::builtin_common_type, T=<int_least64_t,
int_least64_t>]"
(37): here
instantiation of type
"boost::type_traits_detail::mp_valid<boost::type_traits_detail::builtin_common_type,
int_least64_t, int_least64_t>"
(50): here
instantiation of type
"boost::type_traits_detail::mp_defer<boost::type_traits_detail::builtin_common_type,
int_least64_t, int_least64_t>"
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/type_traits/common_type.hpp(96):
here
instantiation of class
"boost::type_traits_detail::common_type_impl<T1, T2> [with
T1=int_least64_t, T2=int_least64_t]"
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/type_traits/common_type.hpp(132):
here
instantiation of class
"boost::type_traits_detail::common_type_decay_helper<T1, T2, T1, T2> [with
T1=int_least64_t, T2=int_least64_t]"
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/type_traits/common_type.hpp(138):
here
[ 3 instantiation contexts not shown ]
instantiation of class
"boost::type_traits_detail::mp_defer_impl<F, T...> [with
F=boost::type_traits_detail::common_type_fold, T=<int_least64_t,
int_least64_t, intmax_t>]"
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/type_traits/common_type.hpp(47):
here
instantiation of class "boost::common_type<T1, T2, T...> [with
T1=int_least64_t, T2=int_least64_t, T=<intmax_t>]"
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/chrono/duration.hpp(256):
here
instantiation of "ToDuration
boost::chrono::detail::duration_cast_aux<FromDuration, ToDuration, Period,
true, false>::operator()(const FromDuration &) const [with
FromDuration=boost::chrono::duration<int_least64_t, boost::nano>,
ToDuration=boost::chrono::seconds, Period=boost::ratio<1L, 1000000000L>]"
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/chrono/duration.hpp(315):
here
instantiation of "ToDuration
boost::chrono::detail::duration_cast<FromDuration,
ToDuration>::operator()(const FromDuration &) const [with
FromDuration=boost::chrono::duration<int_least64_t, boost::nano>,
ToDuration=boost::chrono::seconds]"
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/chrono/duration.hpp(789):
here
instantiation of
"boost::enable_if<boost::chrono::detail::is_duration<ToDuration>,
ToDuration>::type
boost::chrono::duration_cast<ToDuration,Rep,Period>(const
boost::chrono::duration<Rep, Period> &) [with
ToDuration=boost::chrono::seconds, Rep=int_least64_t, Period=boost::nano]"
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/thread/pthread/timespec.hpp(51):
here
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/type_traits/detail/mp_defer.hpp(50):
error: name followed by "::" must be a class or namespace name
detected during:
instantiation of type
"boost::type_traits_detail::mp_defer<boost::type_traits_detail::builtin_common_type,
int_least64_t, int_least64_t>"
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/type_traits/common_type.hpp(96):
here
instantiation of class
"boost::type_traits_detail::common_type_impl<T1, T2> [with
T1=int_least64_t, T2=int_least64_t]"
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/type_traits/common_type.hpp(132):
here
instantiation of class
"boost::type_traits_detail::common_type_decay_helper<T1, T2, T1, T2> [with
T1=int_least64_t, T2=int_least64_t]"
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/type_traits/common_type.hpp(138):
here
instantiation of class "boost::common_type<T1, T2> [with
T1=int_least64_t, T2=int_least64_t]"
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/type_traits/common_type.hpp(37):
here
instantiation of type "boost::common_type_t<int_least64_t,
int_least64_t>"
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/type_traits/common_type.hpp(42):
here
instantiation of type
"boost::type_traits_detail::common_type_fold<int_least64_t, int_least64_t,
intmax_t>"
(47): here
instantiation of class
"boost::type_traits_detail::mp_defer_impl<F, T...> [with
F=boost::type_traits_detail::common_type_fold, T=<int_least64_t,
int_least64_t, intmax_t>]"
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/type_traits/common_type.hpp(47):
here
instantiation of class "boost::common_type<T1, T2, T...> [with
T1=int_least64_t, T2=int_least64_t, T=<intmax_t>]"
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/chrono/duration.hpp(256):
here
instantiation of "ToDuration
boost::chrono::detail::duration_cast_aux<FromDuration, ToDuration, Period,
true, false>::operator()(const FromDuration &) const [with
FromDuration=boost::chrono::duration<int_least64_t, boost::nano>,
ToDuration=boost::chrono::seconds, Period=boost::ratio<1L, 1000000000L>]"
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/chrono/duration.hpp(315):
here
instantiation of "ToDuration
boost::chrono::detail::duration_cast<FromDuration,
ToDuration>::operator()(const FromDuration &) const [with
FromDuration=boost::chrono::duration<int_least64_t, boost::nano>,
ToDuration=boost::chrono::seconds]"
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/chrono/duration.hpp(789):
here
instantiation of
"boost::enable_if<boost::chrono::detail::is_duration<ToDuration>,
ToDuration>::type
boost::chrono::duration_cast<ToDuration,Rep,Period>(const
boost::chrono::duration<Rep, Period> &) [with
ToDuration=boost::chrono::seconds, Rep=int_least64_t, Period=boost::nano]"
/opt/pkg/devel/boost/1.60.0/gnu/4.8.2/64/opt/include/boost/thread/pthread/timespec.hpp(51):
here
}}}
I have reduced it to the following MWE which gives the same error (CUDA
7.0, Boost 1.60):
{{{
#include <boost/type_traits/common_type.hpp>
#include <cstdint>
int main(){
boost::common_type<int_least64_t, int_least64_t, intmax_t>::type i;
}
}}}
-- Ticket URL: <https://svn.boost.org/trac/boost/ticket/11897> Boost C++ Libraries <http://www.boost.org/> Boost provides free peer-reviewed portable C++ source libraries.
This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:19 UTC