Skip to content

Commit

Permalink
fix frontier
Browse files Browse the repository at this point in the history
  • Loading branch information
wilfonba committed Dec 23, 2024
1 parent 256179e commit ae7c02b
Showing 1 changed file with 9 additions and 10 deletions.
19 changes: 9 additions & 10 deletions src/simulation/m_bubbles_EL.fpp
Original file line number Diff line number Diff line change
Expand Up @@ -1166,7 +1166,8 @@ contains

lag_largestep = 0._wp
remove_id = 0
!$acc parallel loop gang vector default(present) reduction(+: lag_largestep) reduction(MAX: remove_id) private(k) copyin(RKstep)
!$acc parallel loop gang vector default(present) reduction(+:lag_largestep) &
!$acc reduction(MAX: remove_id) copyin(RKstep) copy(lag_largestep, remove_id)
do k = 1, nBubs

radiusOld = intfc_rad(k, 2)
Expand Down Expand Up @@ -1238,7 +1239,7 @@ contains
integer :: i, j, k

rkck_errmax = 0._wp
!$acc parallel loop gang vector default(present) reduction(MAX: rkck_errmax) private(k)
!$acc parallel loop gang vector default(present) reduction(MAX: rkck_errmax) copy(rkck_errmax)
do k = 1, nBubs
errb = 0._wp

Expand Down Expand Up @@ -1662,15 +1663,12 @@ contains
lag_void_avg = 0._wp
lag_vol = 0._wp
!$acc parallel loop collapse(3) gang vector default(present) reduction(+:lag_vol,lag_void_avg) &
!$acc reduction(MAX:lag_void_max) private(cell)
do i = 0, m
!$acc reduction(MAX:lag_void_max) copy(lag_vol, lag_void_avg, lag_void_max)
do k = 0, p
do j = 0, n
do k = 0, p
do i = 0, m
lag_void_max = max(lag_void_max, 1._wp - q_beta%vf(1)%sf(i, j, k))
cell(1) = i
cell(2) = j
cell(3) = k
call s_get_char_vol(cell(1), cell(2), cell(3), volcell)
call s_get_char_vol(i, j, k, volcell)
if ((1._wp - q_beta%vf(1)%sf(i, j, k)) > 5.0d-11) then
lag_void_avg = lag_void_avg + (1._wp - q_beta%vf(1)%sf(i, j, k))*volcell
lag_vol = lag_vol + volcell
Expand Down Expand Up @@ -1848,7 +1846,8 @@ contains

integer :: k

!$acc parallel loop gang vector default(present) reduction(MAX: Rmax_glb) reduction(MIN: Rmin_glb) private(k)
!$acc parallel loop gang vector default(present) reduction(MAX:Rmax_glb) &
!$acc reduction(MIN: Rmin_glb) copy(Rmax_glb, Rmin_glb)
do k = 1, nBubs
Rmax_glb = max(Rmax_glb, intfc_rad(k, 1)/bub_R0(k))
Rmin_glb = min(Rmin_glb, intfc_rad(k, 1)/bub_R0(k))
Expand Down

0 comments on commit ae7c02b

Please sign in to comment.