Skip to content

Commit

Permalink
Merge pull request #1783 from eyalshimony/devel
Browse files Browse the repository at this point in the history
Correct num_device value in initialize_GPU
  • Loading branch information
danielpeter authored Jan 22, 2025
2 parents 8f39006 + b4a8a95 commit 169b4f7
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/specfem3D/initialize_simulation.F90
Original file line number Diff line number Diff line change
Expand Up @@ -583,6 +583,8 @@ subroutine initialize_GPU()

if (NPROC == 1 .and. NUMBER_OF_SIMULTANEOUS_RUNS > 1 ) then
num_device = mygroup
else if (NPROC > 1 .and. NUMBER_OF_SIMULTANEOUS_RUNS > 1 ) then
num_device = myrank + mygroup * NPROC
else
num_device = myrank
endif
Expand Down

0 comments on commit 169b4f7

Please sign in to comment.