Skip to content

Commit 182920b

Browse files
Fix return value of find_roc_path when ROCM_PATH is set (#798)
* Fix return value of `find_roc_path` when `ROCM_PATH` is set * Update src/discovery/utils.jl Co-authored-by: Simeon David Schaub <simeon@schaub.rocks> * Bump version number * Fix comment for `find_roc_path` The function is really returning the libdir, not the prefix. --------- Co-authored-by: Simeon David Schaub <simeon@schaub.rocks>
1 parent a697f90 commit 182920b

2 files changed

Lines changed: 6 additions & 3 deletions

File tree

Project.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name = "AMDGPU"
22
uuid = "21141c5a-9bdb-4563-92ae-f87d6854732e"
3-
version = "1.3.5"
3+
version = "1.3.6"
44
authors = ["Julian P Samaroo <jpsamaroo@jpsamaroo.me>", "Valentin Churavy <v.churavy@gmail.com>", "Anton Smirnov <tonysmn97@gmail.com>"]
55

66
[deps]

src/discovery/utils.jl

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,13 @@ function check_rocm_path(path::String)
1515
return path2
1616
end
1717

18-
# Find root ROCm directory.
18+
# Find libdir of ROCm directory.
1919
function find_roc_path()::String
2020
env_dir = get(ENV, "ROCM_PATH", "")
21-
isdir(env_dir) && check_rocm_path(env_dir) != "" && return env_dir
21+
if isdir(env_dir)
22+
rocm_path = check_rocm_path(env_dir)
23+
rocm_path != "" && return rocm_path
24+
end
2225

2326
if Sys.islinux()
2427
hipconfig = Sys.which("hipconfig")

0 commit comments

Comments
 (0)