Linux build of boost using Intel C++ compiler 11.1 or 11.0 and g++ 4.3.3
Hi, I guess this may be a known problem but I wonder if there is any straightforward workaround. I need to install boost on our development machines which run Linux and have g++ 4.3.3 installed. We are wondering about also support the Intel c++ compiler (version 11.1). When trying to build boost 1.39 we get many errors during compilation due to g++ builtins like __builtin_isfinite not being found. Example below. Perhaps I've missed something but using the intel toolset when building still seems to involve using these g++ specific features. Is there a workaround? Thanks Bill For example: "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 "bin.v2/libs/math/build/intel-linux-11.1/release/threading-multi/lround.o" "libs/math/build/../src/tr1/lround.cpp" ...failed intel-linux.compile.c++ bin.v2/libs/math/build/intel-linux-11.1/release/threading-multi/lround.o... intel-linux.compile.c++ bin.v2/libs/math/build/intel-linux-11.1/release/threading-multi/nextafter.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<std::__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 56 of "./boost/math/special_functions/next.hpp" instantiation of "T boost::math::float_next(const T &, const Policy &) [with T=double, Policy=c_policies::c_policy]" at line 153 of "./boost/math/special_functions/next.hpp" instantiation of "T boost::math::nextafter(const T &, 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::nextafter(const T &, const T &) [with T=double]" at line 15 of "libs/math/build/../src/tr1/nextafter.cpp" compilation aborted for libs/math/build/../src/tr1/nextafter.cpp (code 2)
Bill O'Hara wrote:
Hi, I guess this may be a known problem but I wonder if there is any straightforward workaround.
I need to install boost on our development machines which run Linux and have g++ 4.3.3 installed. We are wondering about also support the Intel c++ compiler (version 11.1). When trying to build boost 1.39 we get many errors during compilation due to g++ builtins like __builtin_isfinite not being found. Example below.
Perhaps I've missed something but using the intel toolset when building still seems to involve using these g++ specific features. Is there a workaround?
For example:
"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 "bin.v2/libs/math/build/intel-linux-11.1/release/threading-multi/lround.o" "libs/math/build/../src/tr1/lround.cpp"
...failed intel-linux.compile.c++ bin.v2/libs/math/build/intel-linux-11.1/release/threading-multi/lround.o... intel-linux.compile.c++ bin.v2/libs/math/build/intel-linux-11.1/release/threading-multi/nextafter.o /usr/include/c++/4.3.3/cmath(522): error: identifier "__builtin_isfinite" is undefined return __builtin_isfinite(__type(__f)); ^
It appears to be some misconfiguration of the intel compiler. If you create a source file containing just: #include <cmath> and try to compile it with icpc, does it work? If not, you probably have to ask Intel support what's going on. - Volodya
Hi Vladimir, It appears to be a bug with the Intel compiler. Along the lines you suggested, here is an example. Note that it needs the using namespace std and the 3.14f (explicitly f and not default or d) to appear. The Intel team is aware of the problem. Thanks b. /tmp> cat test.cc #include <iostream> #include <cmath> using namespace std; int main() { std::cout << isfinite(3.14f) << std::endl; return 0; } /tmp> icpc test.cc /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<std::__is_arithmetic<_Tp>::__value, int>::__type std::isfinite(_Tp) [with _Tp=float]" at line 7 of "test.cc" compilation aborted for test.cc (code 2) /tmp> icpc --version icpc (ICC) 11.1 20090630 Copyright (C) 1985-2009 Intel Corporation. All rights reserved. /tmp> g++ --version g++ (Ubuntu 4.3.3-5ubuntu4) 4.3.3 Copyright (C) 2008 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. On Tue, Aug 25, 2009 at 10:01 PM, Vladimir Prus <vladimir@codesourcery.com>wrote:
Bill O'Hara wrote:
Hi, I guess this may be a known problem but I wonder if there is any straightforward workaround.
I need to install boost on our development machines which run Linux and have g++ 4.3.3 installed. We are wondering about also support the Intel c++ compiler (version 11.1). When trying to build boost 1.39 we get many errors during compilation due to g++ builtins like __builtin_isfinite not being found. Example below.
Perhaps I've missed something but using the intel toolset when building still seems to involve using these g++ specific features. Is there a workaround?
For example:
"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
"bin.v2/libs/math/build/intel-linux-11.1/release/threading-multi/lround.o"
"libs/math/build/../src/tr1/lround.cpp"
...failed intel-linux.compile.c++
bin.v2/libs/math/build/intel-linux-11.1/release/threading-multi/lround.o...
intel-linux.compile.c++
bin.v2/libs/math/build/intel-linux-11.1/release/threading-multi/nextafter.o
/usr/include/c++/4.3.3/cmath(522): error: identifier "__builtin_isfinite" is undefined return __builtin_isfinite(__type(__f)); ^
It appears to be some misconfiguration of the intel compiler. If you create a source file containing just:
#include <cmath>
and try to compile it with icpc, does it work? If not, you probably have to ask Intel support what's going on.
- Volodya
_______________________________________________ Boost-users mailing list Boost-users@lists.boost.org http://lists.boost.org/mailman/listinfo.cgi/boost-users
I guess this may be a known problem but I wonder if there is any straightforward workaround.
I need to install boost on our development machines which run Linux and have g++ 4.3.3 installed. We are wondering about also support the Intel c++ compiler (version 11.1). When trying to build boost 1.39 we get many errors during compilation due to g++ builtins like __builtin_isfinite not being found. Example below.
Perhaps I've missed something but using the intel toolset when building still seems to involve using these g++ specific features. Is there a workaround?
The errors look like either an Intel bug, or an installation error. What happens if you have a hello world application that just calls std::isfinite ? John.
2009/8/28 John Maddock <john@johnmaddock.co.uk>:
I guess this may be a known problem but I wonder if there is any straightforward workaround.
I need to install boost on our development machines which run Linux and have g++ 4.3.3 installed. We are wondering about also support the Intel c++ compiler (version 11.1). When trying to build boost 1.39 we get many errors during compilation due to g++ builtins like __builtin_isfinite not being found. Example below.
Perhaps I've missed something but using the intel toolset when building still seems to involve using these g++ specific features. Is there a workaround?
The errors look like either an Intel bug, or an installation error.
What happens if you have a hello world application that just calls std::isfinite ?
John.
It is a known bug when using recent GCC headers with Intel compiler 11 (I had the issue during last Christmas holidays and also sent a mail here). Matthieu -- Information System Engineer, Ph.D. Website: http://matthieu-brucher.developpez.com/ Blogs: http://matt.eifelle.com and http://blog.developpez.com/?blog=92 LinkedIn: http://www.linkedin.com/in/matthieubrucher
participants (4)
-
Bill O'Hara
-
John Maddock
-
Matthieu Brucher
-
Vladimir Prus