xuhuisheng / rocm-build

build scripts for ROCm
Apache License 2.0
181 stars 35 forks source link

can't find hipcc #2

Closed takfate closed 3 years ago

takfate commented 3 years ago

when i exec bash navi10/22.rocblas.sh , something is worng.

CMake Error at /usr/share/cmake-3.16/Modules/CMakeDetermineCXXCompiler.cmake:48 (message):
  Could not find compiler set in environment variable CXX:

  /opt/rocm/bin/hipcc.

Call Stack (most recent call first):
  CMakeLists.txt:31 (project)

CMake Error: CMAKE_CXX_COMPILER not set, after EnableLanguage
-- Configuring incomplete, errors occurred!

i need to install something to get hipcc?

xuhuisheng commented 3 years ago

yes, please installl rocm-dev to get hip, hipcc is in hip.

takfate commented 3 years ago

ok. when I execute bash 34.miopen.sh. the error is

CMake Error at /home/work/ROCm/MIOpen/install_deps.cmake:45 (message):
  Download for install.cmake failed: "Couldn't connect to server"
xuhuisheng commented 3 years ago

There are many dependencies for MIOpen. install_deps.cmake is used to download the sources of these dependencies from github or other website. If your network doesn't work very well. I suggest you using a proxy to speed up. or try some more times.

PS: AMDMIGraphX using more dependencies than MIOpen. But AMDMIGraphX isn't depended by TF/Pytorch.

takfate commented 3 years ago

I have set the proxy of terminal, and I can curl www.google.com successfully.But likely executing CmakeGet never worked.

xuhuisheng commented 3 years ago

There is really no better way for downloading dependencies from github. The good news is you only need install dependencies once.

takfate commented 3 years ago

他这些依赖都要装到哪里去啊,我能不能自己装。 sqlite,boost,half。 我现在是sqlite那里 -X autotools有问题,他自动下载,直接就无法连接。

xuhuisheng commented 3 years ago

记录了一下关联信息,有兴趣可以研究一下,但是还是需要找个网络好的地方下载。 关于依赖,因为ROCm采用了 pfultz2 的cmakeget,所以会去自动下载依赖,本地cmake编译,问题是下载慢,所以要研究本地编译依赖。

    需要先安装cmake-get
    sqlite3,http:// 这种就是去指定位置下载或者复制,支持http或file协议
    boost@1.72这种没有任何标记的对应组件的配置在rocm-recipes里。
        https://github.com/pfultz2/rocm-recipes/tree/master/recipes/boost/1.72
    pfultz2/rocm-recipes 这种带分隔符的就是去github下载
    下载以后,再查找对应的requirements.txt,递归安装依赖
    -X 表示使用指定cmake,对应cmake放在https://github.com/pfultz2/cget/tree/master/cget/cmake
takfate commented 3 years ago

我之前尝试了直接安装依赖: sqlite直接apt install libsqlite3-dev boost直接像miopen仓库说的那样apt install boost-filesystem等, half直接运行了那个xx.half.sh 算是把流程都走完了,pytorch也编译完了。但是import还是有问题。

Sohnia commented 3 years ago

我也遇到了同样的问题。

CMake Error at /usr/share/cmake-3.16/Modules/CMakeDetermineCXXCompiler.cmake:48 (message): Could not find compiler set in environment variable CXX:

hipcc.

Call Stack (most recent call first): CMakeLists.txt:54 (project)

CMake Error: CMAKE_CXX_COMPILER not set, after EnableLanguage CMake Error: CMAKE_Fortran_COMPILER not set, after EnableLanguage -- Configuring incomplete, errors occurred!

xuhuisheng commented 3 years ago

@Sohnia 请问是哪个脚本报错,是否已编译安装hip?

Sohnia commented 3 years ago

我执行的是这个命令

If you want to compile rocSPARSE manually, can use my forked rocSPARSE repository, the patch had be commited to the default branch.

Install ROCm https://rocmdocs.amd.com/en/latest/Installation_Guide/Installation-Guide.html#ubuntu
At least install rocm-dev and rocm-libs sudo apt install rocm-dev rocm-libs
git clone https://github.com/xuhuisheng/rocSPARSE
cd rocSPARSE
bash install.sh -di
Sohnia commented 3 years ago

@Sohnia 请问是哪个脚本报错,是否已编译安装hip?

没有编译安装hip

xuhuisheng commented 3 years ago

@Sohnia rocsparse属于rocm-libs,依赖rocm-dev中包含的组件,可以先按照官方文档安装rocm-dev再编译rocsparse。如果资源足够,不怕花时间,也可以自己编译rocm-dev包含的组件,按照仓库里脚本的编号从11执行到19

同学们要仔细看文档哈,文档里写了至少要安装rocm-dev,我又加了一份中文版 https://github.com/xuhuisheng/rocm-build/blob/develop/docs/gfx803_zh_CN.md

xuhuisheng commented 3 years ago

Close this issue now, if still have problem, please create a new issue. Thank you.