jhuber6 wrote:

> This doesn't make sense, the ROCm packages may be just badly made by AMD.
> 
> When I temporarily remove `/usr/include/hsa` without uninstalling 
> `libhsa-runtime-dev` **AND** while using 
> `-DLIBOMPTARGET_FORCE_DLOPEN_LIBHSA=ON`, I can build LLVM18 without patch.
> 
> With `-DLIBOMPTARGET_FORCE_DLOPEN_LIBHSA=OFF` CMake complains that 
> `/usr/include/hsa` is missing.
> 
> So it looks like I'm tracking a ROCm packaging bug from AMD side.

I don't think AMD handles the actual packaging, that's on the maintainers for 
your distribution. I'm guessing that the HSA runtime is a separate package from 
ROCm and gets put somewhere else for whatever reason. I don't have any issues 
like that with my distribution.

> But I still don't get why LLVM doesn't use its own HSA by default and doesn't 
> use its own headers for enum values used in its own code.

It does in the main branch, but I think you're right that the logic causes it 
to look at the system one first since `hsa/hsa.h` is higher up the search list. 
Should probably do something about that.

https://github.com/llvm/llvm-project/pull/95484
_______________________________________________
llvm-branch-commits mailing list
llvm-branch-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

Reply via email to