Closed tpkessler closed 2 months ago
i guess i have a similar issue on Gentoo while compiling caffe2
Can't exec "/usr/../llvm/bin/clang": No such file or directory at /usr/bin//hipcc.pl line 178.
Use of uninitialized value $HIP_CLANG_RT_LIB in scalar chomp at /usr/bin//hipcc.pl line 179.
Warning: The --amdgpu-target option has been deprecated and will be removed in the future. Use --offload-arch instead.
sh: line 1: /usr/../llvm/bin/clang: No such file or directory
HIP_CLANG_PATH is set to /usr/lib/llvm/16/bin whereas hipcc still picks up the default ROCM_PATH/../llvm/bin/clang
Hi @PIPIPIG233666! Your issue is the same as I reported for https://github.com/ROCmSoftwarePlatform/rocALUTION/issues/174 It's a bug in the cmake config file for HIP.
(https://github.com/ROCmSoftwarePlatform/rocALUTION/pull/17) It's a bug in the cmake config file for HIP.
Thanks! It should be #174 instead of ROCm/HIPCC#17 but thank you for the heads up.
Hi @PIPIPIG233666! Your issue is the same as I reported for ROCmSoftwarePlatform/rocALUTION#174 It's a bug in the cmake config file for HIP.
actually i fixed mine by setting HIP_CLANG_PATH as env var, somehow the perl module var still didn't get picked up tho
ROCm 6.0.2 still suffers from this issue. @Mystro256 can you shed some light on this?
@tpkessler Internal ticket is created is created to investigate this issue. Thanks!
Hi @PIPIPIG233666 @tpkessler, these issues were resolved in the new release of ROCm 6.2 - see this commit: https://github.com/ROCm/llvm-project/commit/ecb18b9a75ba1908750e510cb291ce9955311bd5
Please try checking out and building against the rocm/llvm-project (rocm-6.2.x branch). While I was able to reproduce your issue from a source build in earlier versions, I see the correct output in the most recent rocm.
/llvm-project/amd/hipcc/build$ ./hipcc.bin --version
HIP version: 6.2.0-0
AMD clang version 18.0.0git (https://github.com/RadeonOpenCompute/llvm-project roc-6.2.0 24292 26466ce804ac523b398608f17388eb6d605a3f09)
Target: x86_64-unknown-linux-gnu
Thread model: posix
InstalledDir: /opt/rocm/lib/llvm/bin
Configuration file: /opt/rocm-6.2.0/lib/llvm/bin/clang++.cfg
If this issue recurs, please reopen the ticket.
Aside: Those shell errors are due to use of mkdtemp instead of mk(s)temp here, resulting in an attempted "write" to a temporary directory (which was meant to be a temporary file; you cannot write to a directory).
Hi! After building the 5.6.0 branch for Arch Linux I noted that
hipcc.bin
doesn't work properly as the compiler path isn't picked correctly. The output ofis
The issue is that
complierPath
[sic!] as constructed insrc/hipBin_amd.h::HipBinAmd::constructCompilerPath
relies ongetRoccmPath()
insrc/hipBin_base.h
which only returns the content of the environment varROCM_PATH
. If this is not set,hipClangPath
is an empty path. The perl script instead defaults to/opt/rocm/
asROCM_PATH
when no env var is set.But setting
ROCM_PATH
doesn't really fix my issue.with output
It does report the correct path but there's still
Hip Clang Compiler not found
raised bysrc/hipBin_amd.h::HipBinAmd::getCompilerVersion
. I haven't figured out yet why this doesn't work.Furthermore I'm wondering where the shell errors
sh: line 1 ...
are coming from.The perl script works as expected: