Skip to content

Commit

Permalink
Fix advice on how to run code on multiple GPUs
Browse files Browse the repository at this point in the history
  • Loading branch information
MasonProtter authored May 13, 2022
1 parent e762285 commit 9e0f4c7
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions docs/src/usage/multigpu.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,12 +48,10 @@ threads](@ref).

```julia
@sync begin
@async begin
device!(0)
@async device!(0) do
# do work on GPU 0 here
end
@async begin
device!(1)
@async device!(1) do
# do work on GPU 1 here
end
end
Expand Down

0 comments on commit 9e0f4c7

Please sign in to comment.