Intel® C++ Compiler
Community support and assistance for creating C++ code that runs on platforms based on Intel® processors.
7944 Discussions

Boost 1.39 with Intel C++ compiler 11.0?

billtohara
Beginner
470 Views
Has anyone managed to build the most recent release of Boost 1.39 with Intel C++ 11.0? When I try I get many errors, such as the one below, related to builtin functions like __builtin_isfinite(). There seem to be GNU style builtins - are there equivalents for Intel?


"icpc" -c -xc++ -O3 -w1 -inline-level=2 -pthread -fPIC -DBOOST_ALL_NO_LIB=1 -DBOOST_MATH_TR1_DYN_LINK=1 -DNDEBUG -I"." -c -o "/tmp/build-boost/boost/bin.v2/libs/math/build/intel-linux/release/threading-multi/nextafter.o" "libs/math/build/../src/tr1/nextafter.cpp"

...failed intel-linux.compile.c++ /tmp/build-boost/boost/bin.v2/libs/math/build/intel-linux/release/threading-multi/nextafter.o...
intel-linux.compile.c++ /tmp/build-boost/boost/bin.v2/libs/math/build/intel-linux/release/threading-multi/nexttoward.o
intel-linux.compile.c++ /tmp/build-boost/boost/bin.v2/libs/math/build/intel-linux/release/threading-multi/round.o
/usr/include/c++/4.3.3/cmath(522): error: identifier "__builtin_isfinite" is undefined
return __builtin_isfinite(__type(__f));
^
detected during:
instantiation of "__gnu_cxx::__enable_if<:__IS_ARITHMETIC><_Tp>::__value, int>::__type std::isfinite(_Tp) [with _Tp=double]" at line 262 of "./boost/math/special_functions/fpclassify.hpp"
instantiation of "bool boost::math::detail::isfinite_impl(T, const boost::math::detail::native_tag &) [with T=double]" at line 310 of "./boost/math/special_functions/fpclassify.hpp"
instantiation of "bool boost::math::isfinite(T) [with T=double]" at line 23 of "./boost/math/special_functions/round.hpp"
instantiation of "T boost::math::round(const T &, const Policy &) [with T=double, Policy=c_policies::c_policy]" at line 27 of "libs/math/build/../src/tr1/c_policy.hpp"
instantiation of "T c_policies::round(const T &) [with T=double]" at line 15 of "libs/math/build/../src/tr1/round.cpp"

compilation aborted for libs/math/build/../src/tr1/round.cpp (code 2)
0 Kudos
4 Replies
TimP
Honored Contributor III
470 Views
So you have verified that icpc 11.0 doesn't fully support g++ 4.3.3. I believe that's documented. You could use an earlier version of /usr/include/c++ or check whether current icpc supports this.
0 Kudos
billtohara
Beginner
470 Views
Quoting - tim18
So you have verified that icpc 11.0 doesn't fully support g++ 4.3.3. I believe that's documented. You could use an earlier version of /usr/include/c++ or check whether current icpc supports this.

It looks like this is related to a compiler bug; see "icpc, g++ 4.3.2 and __builtin_isfinite" in this forum. I also checked with 11.1 and it persists there.
0 Kudos
thevinn
Beginner
470 Views
I had no problems building boost (once I added the necessary incantations to site-config.jam and the bjam command line).

I am using boost_1_39_0 and this version of Intel C++:

...Compiler11.1�38binia32

0 Kudos
billtohara
Beginner
470 Views
Quoting - thevinn
I had no problems building boost (once I added the necessary incantations to site-config.jam and the bjam command line).

I am using boost_1_39_0 and this version of Intel C++:

...Compiler11.1�38binia32



Can I assume, based off the path you give, that you are compiling on Windows? The problem for me is on linux.

thanks
bill
0 Kudos
Reply