英特尔线程构建基块gcc版本

时间:2020-06-19 12:25:26

标签: gcc parallel-processing intel tbb gcc4.8

我已经安装了英特尔并行工作室。但是,在tbb的目录结构中查看gcc编译器时,似乎使用的是4.8。我正在尝试建立另一个依赖于tbb的存储库,该存储库给出以下错误,我可以肯定是由旧版本的gcc引起的。

错误:

/usr/include/tbb/concurrent_vector.h(667): error: ambiguous "?" operation: second operand of type "tbb::internal::concurrent_vector_base_v3::size_type" can be converted to third operand type "tbb::atomic<unsigned long>", and vice versa

/usr/include/tbb/concurrent_vector.h(680): error: ambiguous "?" operation: second operand of type "tbb::internal::concurrent_vector_base_v3::size_type" can be converted to third operand type "tbb::atomic<unsigned long>", and vice versa

2 errors detected in the compilation of "/tmp/tmpxft_00000d0e_00000000-4_gpu_handle.cpp4.ii".
make: *** [build/objs/cuda/tensor/gpu_handle.o] Error 2

tbb的目录结构如下

mm470@pc5-036-l:~/usr/parallel_studio_xe_2020/compilers_and_libraries_2020/linux/tbb/lib/intel64/gcc4.8 $ dir
libtbb.so  libtbb.so.2  libtbb_debug.so.2  libtbbmalloc.so  libtbbmalloc.so.2  libtbbmalloc_debug.so.2

首先有人知道我对导致此错误的gcc版本的直觉是否正确,其次我将如何使用较新版本的gcc安装并行Studio。我在计算机上的gcc是更高版本。

mm470@pc5-036-l:~/usr/parallel_studio_xe_2020/compilers_and_libraries_2020/linux/tbb/lib/intel64/gcc4.8 $ gcc --version
gcc (GCC) 6.3.1 20170216 (Red Hat 6.3.1-3)
Copyright (C) 2016 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.

1 个答案:

答案 0 :(得分:0)

gcc版本与将要使用的gnu运行时有关。 AFAIR Intel编译器不提供自己的运行时,也不使用gnu运行时。它们(gcc运行时)在早期版本和4.8版本之间进行了一些重大更改。

AFAIS /usr/include/tbb/concurrent_vector.h是从Linux发行版而不是编译器软件包中本地安装的TBB。尝试获取编译器环境脚本的源代码以设置不同的PATH。