Skip to content

Commit 6463787

Browse files
committed
Allow for io param
1 parent 756602c commit 6463787

1 file changed

Lines changed: 5 additions & 4 deletions

File tree

src/utils.jl

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
function versioninfo()
1+
function versioninfo(io::IO=stdout)
22
@info "AMDGPU versioninfo"
33
_status(st::Bool) = st ? "+" : "-"
44
_libpath(p::String) = isempty(p) ? "-" : p
@@ -15,14 +15,15 @@ function versioninfo()
1515
_status(functional(:MIOpen)) "MIOpen" _ver(:MIOpen, MIOpen.version) _libpath(libMIOpen_path);
1616
]
1717

18-
PrettyTables.pretty_table(data; column_labels=[
18+
PrettyTables.pretty_table(io, data; column_labels=[
1919
"Available", "Name", "Version", "Path"],
2020
alignment=[:c, :l, :l, :l])
2121

2222
if functional(:hip)
23-
println()
23+
println(io)
2424
@info "AMDGPU devices"
25-
display(AMDGPU.devices())
25+
show(io, MIME"text/plain"(), AMDGPU.devices())
26+
println(io)
2627
end
2728
return
2829
end

0 commit comments

Comments
 (0)