Skip to content
Snippets Groups Projects
Commit 38bb4c90 authored by Lionel GUEZ's avatar Lionel GUEZ
Browse files

Remove dummy arguments of `get_snapshot`

Remove dummy arguments nlon, nlat, corner, step, copy, `max_delta` of
procedure `get_snapshot`, use module variables instead.
parent c35c3b18
No related branches found
No related tags found
No related merge requests found
......@@ -127,8 +127,8 @@ program eddy_graph
! 2. Prologue:
do k = k_begin, k_begin + max_delta
call get_snapshot(flow(k - k_begin + 1), nlon, nlat, corner, step, copy, &
hshpc, ssm, k, k_end, rank, n_proc, max_delta) ! (read)
call get_snapshot(flow(k - k_begin + 1), hshpc, ssm, k, k_end, rank, &
n_proc) ! (read)
end do
do delta = 1, max_delta
......@@ -144,8 +144,7 @@ program eddy_graph
call dispatch_snapshot(flow(1), unit_isolated, rank, k_begin, max_delta, &
k = k - max_delta - 1)
flow(:max_delta) = flow(2:)
call get_snapshot(flow(max_delta + 1), nlon, nlat, corner, step, copy, &
hshpc, ssm, k, k_end, rank, n_proc, max_delta)
call get_snapshot(flow(max_delta + 1), hshpc, ssm, k, k_end, rank, n_proc)
do delta = 1, max_delta
call overlap(flow, nlon, nlat, periodic, dist_lim, e_overestim, k, &
......@@ -160,8 +159,7 @@ program eddy_graph
call dispatch_snapshot(flow(1), unit_isolated, rank, k_begin, max_delta, &
k = k - max_delta - 1)
flow(:max_delta) = flow(2:)
call get_snapshot(flow(max_delta + 1), nlon, nlat, corner, step, copy, &
hshpc, ssm, k, k_end, rank, n_proc, max_delta)
call get_snapshot(flow(max_delta + 1), hshpc, ssm, k, k_end, rank, n_proc)
! (reception)
! Stitching:
......
......@@ -4,21 +4,15 @@ module get_snapshot_m
contains
subroutine get_snapshot(s, nlon, nlat, corner, step, copy, hshp, ssm, k, &
k_end, rank, n_proc, max_delta)
subroutine get_snapshot(s, hshp, ssm, k, k_end, rank, n_proc)
use config_graph_m, only: copy, max_delta
use derived_types, only: snapshot, shpc_slice_handler, shpc_slice_meta
use read_grid_m, only: nlon, nlat, corner, step
use read_snapshot_m, only: read_snapshot
use recv_snapshot_m, only: recv_snapshot
type(snapshot), intent(out):: s
integer, intent(in):: nlon, nlat
real, intent(in):: corner(:) ! (2) longitude and latitude of the
! corner of the whole grid, in rad
real, intent(in):: step(:) ! (2) longitude and latitude steps, in rad
integer, intent(in):: copy
TYPE(shpc_slice_handler), intent(in):: hshp(:) ! (n_slices)
type(shpc_slice_meta), intent(in):: ssm(:) ! (n_slices)
integer, intent(in):: k ! date index
......@@ -26,10 +20,6 @@ contains
integer, intent(in):: rank ! of MPI process
integer, intent(in):: n_proc ! number of MPI processes
integer, intent(in):: max_delta
! maximum interval of date indices between which we look for
! overlapping of eddies
!--------------------------------------------------------------
if (rank == n_proc - 1 .or. k <= k_end - max_delta) then
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment