TensorFlow:从源代码安装OpenCl的编译错误

时间:2017-02-25 15:44:16

标签: compilation tensorflow opencl fedora-25

您好我已经按照说明从源代码安装,并在运行./configure并提供了clang / ++和ComputeCpp路径,并且是OpenCL。

使用Bazel命令:

bazel build --config opt --config=sycl //tensorflow/tools  /pip_package:build_pip_package

我收到以下编译错误:

clang++: symbol lookup error: /usr/bin/clang++: undefined symbol: LLVMInitializeMipsAsmParser

我查找了符号,它属于Rust,它没有安装在我的系统上,也无法查看如何安装它或此TensorFlow安装所需的库。它只发生在我安装OpenCL时。所以它似乎与ComputeCpp一起用于OpenCL。我在Fedora 25上安装(Yey)

任何想法都将不胜感激。另外,每次运行时如何阻止它下载./Configure它是否可以读取它已经下载的文件,如果是这样的话?

由于 Hbyte

1 个答案:

答案 0 :(得分:1)

首先,Fedora 25尚未得到ComputeCpp的正式支持。虽然,我们会竭尽全力提供帮助。

您不需要更改任何bazel构建文件。 你能确认ComputeCpp的安装位置吗?

  

我插入了ompute ++,现在发现我的/ usr / include路径中的头文件没有被使用。

您是说在配置TF以使用OpenCL后未选择系统头?

从TensorFlow设置的角度来看你应该指出 ./configure到了什么位置..没有必要在任何地方复制标题/二进制文件。

例如我的ComputeCpp在我的主目录

Do you wish to build TensorFlow with OpenCL support? [y/N] y OpenCL support will be enabled for TensorFlow Do you wish to build TensorFlow with CUDA support? [y/N] No CUDA support will be enabled for TensorFlow which: no clang++-3.6 in (/usr/lib64/ccache:/usr/local/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/home/luke/.local/bin:/home/luke/bin) Please specify which C++ compiler should be used as the host C++ compiler. [Default is ]: /usr/bin/clang++ Please specify which C compiler should be used as the host C compiler. [Default is /usr/local/bin/clang-3.6]: /usr/bin/clang Please specify the location where ComputeCpp for SYCL 1.2 is installed. [Default is /usr/local/computecpp]: /home/luke/ComputeCpp-CE-0.1.2-Linux 至于whl包,它归结为谷歌,但据我所知TensorFlow也没有正式支持Fedora 25。

如果您有构建系统的修复程序,请创建Pull Request:)

如果为主机编译器选择GCC会怎样?

是否有可能在GitHub上打开一个问题来跟踪此进展?