[PATCH] D59321: AMDGPU: Teach toolchain to link rocm device libs

Matt Arsenault via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Apr 1 14:05:06 PDT 2020


arsenm marked 2 inline comments as done.
arsenm added a comment.

In D59321#1955405 <https://reviews.llvm.org/D59321#1955405>, @hliao wrote:

> Do we have a better way to avoid adding those empty bitcode files?


No, we need the files to exist for tests. This is what existing bitcode link tests do



================
Comment at: clang/lib/Driver/ToolChains/AMDGPU.h:44-46
+  //RocmVersion Version = RocmVersion::UNKNOWN;
+  SmallString<0> InstallPath;
+  //SmallString<0> BinPath;
----------------
hliao wrote:
> sounds to me that both `Version` and `BinPath` should be added. They will be used eventually.
It's easy to add when needded


================
Comment at: clang/lib/Driver/ToolChains/HIP.h:76
 
-class LLVM_LIBRARY_VISIBILITY HIPToolChain final : public AMDGPUToolChain {
+class LLVM_LIBRARY_VISIBILITY HIPToolChain final : public ROCMToolChain {
 public:
----------------
hliao wrote:
> Do you miss the change in HIP.cpp? That constructor needs revising as the base class is changed.
Yes, I fixed this locally already


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D59321/new/

https://reviews.llvm.org/D59321





More information about the cfe-commits mailing list