Skip to content

Commit e1591e3

Browse files
author
Daniel Vickers
committed
Passes cray compiler tests
1 parent 3dc61e0 commit e1591e3

File tree

2 files changed

+10
-4
lines changed

2 files changed

+10
-4
lines changed

src/common/m_compute_levelset.fpp

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -287,8 +287,10 @@ contains
287287
bottom_left(1) = -length_x/2
288288
bottom_left(2) = -length_y/2
289289

290-
$:GPU_PARALLEL_LOOP(private='[i,j,k,min_dist,idx,side_dists,xy_local,dist_vec]', copy='[levelset%sf,levelset_norm%sf]',&
291-
& copyin='[ib_patch_id,center,bottom_left,top_right,inverse_rotation,rotation,x_cc,y_cc]', collapse=2)
290+
! $:GPU_PARALLEL_LOOP(private='[i,j,k,min_dist,idx,side_dists,xy_local,dist_vec]', copy='[levelset%sf,levelset_norm%sf, dbg]',&
291+
! & copyin='[ib_patch_id,center,bottom_left,top_right,inverse_rotation,rotation,x_cc,y_cc]', collapse=2)
292+
$:GPU_PARALLEL_LOOP(private='[i,j,k,min_dist,idx,side_dists,xy_local,dist_vec]', &
293+
& copyin='[ib_patch_id,center,bottom_left,top_right,inverse_rotation,rotation]', collapse=2)
292294
do i = 0, m
293295
do j = 0, n
294296
xy_local = [x_cc(i) - center(1), y_cc(j) - center(2), 0._wp]
@@ -330,6 +332,7 @@ contains
330332
end do
331333
end do
332334

335+
333336
end subroutine s_rectangle_levelset
334337

335338
pure subroutine s_cuboid_levelset(ib_patch_id, levelset, levelset_norm)

src/simulation/m_ibm.fpp

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -927,7 +927,9 @@ contains
927927
integer :: i, ierr
928928
929929
! Clears the existing immersed boundary indices
930-
ib_markers%sf = 0
930+
ib_markers%sf = 0._wp
931+
levelset%sf = 0._wp
932+
levelset_norm%sf = 0._wp
931933
932934
! recalulcate the rotation matrix based upon the new angles
933935
do i = 1, num_ibs
@@ -941,7 +943,8 @@ contains
941943
! recompute the new ib_patch locations and broadcast them.
942944
call s_apply_ib_patches(ib_markers%sf(0:m, 0:n, 0:p), levelset, levelset_norm)
943945
call s_populate_ib_buffers() ! transmits the new IB markers via MPI
944-
$:GPU_UPDATE(device='[ib_markers%sf, levelset%sf, levelset_norm%sf]')
946+
$:GPU_UPDATE(device='[ib_markers%sf]')
947+
$:GPU_UPDATE(host='[levelset%sf, levelset_norm%sf]')
945948
946949
! recalculate the ghost point locations and coefficients
947950
call s_find_num_ghost_points(num_gps, num_inner_gps)

0 commit comments

Comments
 (0)