Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix issues with Cray #3

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion openacc_cuda_sample/cray.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,6 @@ if (TARGET_GPU)
set(CMAKE_Fortran_FLAGS_DEBUG "${CMAKE_Fortran_FLAGS_DEBUG} -g")
else()
set(CMAKE_Fortran_FLAGS_DEBUG "${CMAKE_Fortran_FLAGS_DEBUG} -O0 -g -eZ -eD -Rb -Rc -Rd -Rp -Rs")
endif()
endif()

set(CMAKE_SHARED_LIBRARY_LINK_Fortran_FLAGS "")
8 changes: 4 additions & 4 deletions openacc_cuda_sample/src/m_parameterizations.f90
Original file line number Diff line number Diff line change
Expand Up @@ -68,10 +68,10 @@ SUBROUTINE microphysics(npx, npy, nlev, t, qc, qv)
IMPLICIT NONE

! arguments
INTEGER, INTENT(IN) :: npx, npy, nlev ! dimension of inputs
REAL*8, INTENT(INOUT) :: t(:,:,:) ! temperature
REAL*8, INTENT(IN) :: qc(:,:,:) ! cloud water content
REAL*8, INTENT(INOUT) :: qv(:,:,:) ! water vapour content
INTEGER, INTENT(IN) :: npx, npy, nlev ! dimension of inputs
REAL*8, INTENT(INOUT) :: t(npx,npy,nlev) ! temperature
REAL*8, INTENT(IN) :: qc(npx,npy,nlev) ! cloud water content
REAL*8, INTENT(INOUT) :: qv(npx,npy,nlev) ! water vapour content

! local variables
INTEGER :: i, j, k ! loop indices
Expand Down
6 changes: 5 additions & 1 deletion openacc_cuda_sample/src/main.f90
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,10 @@ PROGRAM main

! local variables
INTEGER :: ntstep
INTEGER :: mpi_error
INTEGER, parameter :: itimloop = 5


CALL MPI_init(mpi_error)
CALL initialize()

!----------------------------------------------------------------------------
Expand Down Expand Up @@ -49,4 +51,6 @@ PROGRAM main

CALL cleanup()

CALL MPI_finalize(mpi_error)

END PROGRAM main