Skip to content

Commit

Permalink
[CMAKE] Compatible for ROCm before 3.7 (#6359)
Browse files Browse the repository at this point in the history
  • Loading branch information
tqchen authored Aug 28, 2020
1 parent c899b3c commit b368f9d
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions cmake/util/FindROCM.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,13 @@ macro(find_rocm use_rocm)
if(__rocm_sdk)
set(ROCM_INCLUDE_DIRS ${__rocm_sdk}/include)
find_library(ROCM_HIPHCC_LIBRARY amdhip64 ${__rocm_sdk}/lib)
# Backward compatible with before ROCm3.7
if(NOT ROCM_HIPHCC_LIBRARY)
find_library(ROCM_HIPHCC_LIBRARY hip_hcc ${__rocm_sdk}/lib)
endif()
find_library(ROCM_MIOPEN_LIBRARY MIOpen ${__rocm_sdk}/lib)
find_library(ROCM_ROCBLAS_LIBRARY rocblas ${__rocm_sdk}/lib)

if(ROCM_HIPHCC_LIBRARY)
set(ROCM_FOUND TRUE)
endif()
Expand Down

0 comments on commit b368f9d

Please sign in to comment.