Skip to content

Commit

Permalink
Conditionalise librocfft-device so's out of rocm5.5 (pytorch#22)
Browse files Browse the repository at this point in the history
Co-authored-by: Jack Taylor <[email protected]>
  • Loading branch information
jithunnair-amd and jataylo authored Feb 14, 2023
1 parent fdad948 commit 21cc230
Showing 1 changed file with 11 additions and 4 deletions.
15 changes: 11 additions & 4 deletions manywheel/build_rocm.sh
Original file line number Diff line number Diff line change
Expand Up @@ -84,10 +84,6 @@ ROCM_SO_FILES=(
"libmagma.so"
"librccl.so"
"librocblas.so"
"librocfft-device-0.so"
"librocfft-device-1.so"
"librocfft-device-2.so"
"librocfft-device-3.so"
"librocfft.so"
"librocm_smi64.so"
"librocrand.so"
Expand All @@ -97,6 +93,13 @@ ROCM_SO_FILES=(
"libroctx64.so"
)

if [[ $ROCM_INT -lt 50500 ]]; then
ROCM_SO_FILES+=("librocfft-device-0.so")
ROCM_SO_FILES+=("librocfft-device-1.so")
ROCM_SO_FILES+=("librocfft-device-2.so")
ROCM_SO_FILES+=("librocfft-device-3.so")
fi

if [[ $ROCM_INT -ge 50400 ]]; then
ROCM_SO_FILES+=("libhiprtc.so")
fi
Expand Down Expand Up @@ -164,6 +167,10 @@ do
if [[ -z $file_path ]]; then
file_path=($(find $ROCM_HOME/ -name "$lib")) # Then search in ROCM_HOME
fi
if [[ -z $file_path ]]; then
echo "Warning: Library file $lib is not found."
file_path="NOT_FOUND"
fi
ROCM_SO_PATHS[${#ROCM_SO_PATHS[@]}]="$file_path" # Append lib to array
done

Expand Down

0 comments on commit 21cc230

Please sign in to comment.