MODFLOW 6 version 6.9.0.dev0
USGS Modular Hydrologic Model
Loading...
Searching...
No Matches
mpiroutermodule::mpiroutertype Type Referenceabstract
Inheritance diagram for mpiroutermodule::mpiroutertype:
Inheritance graph
Collaboration diagram for mpiroutermodule::mpiroutertype:
Collaboration graph

Public Member Functions

procedure initialize (this)
procedure route_all (this, stage)
 This will route all remote data from the global models and exchanges over MPI, for a.
procedure route_sln (this, virtual_sol, stage)
 This will route all remote data from models and exchanges in a particular solution over MPI,.
procedure finalize (this)
procedure destroy (this)
procedure(initialize_if), deferred initialize (this)
procedure(route_all_if), deferred route_all (this, stage)
procedure(route_sln_if), deferred route_sln (this, virtual_sol, stage)
procedure(finalize_if), deferred finalize (this)
procedure(destroy_if), deferred destroy (this)

Public Attributes

integer(i4b), dimension(:), pointer model_proc_ids
type(stlvecint) senders
 the process ids to receive data from
type(stlvecint) receivers
 the process ids to send data to
type(vdcptrtype), dimension(:), pointer all_models => null()
 all virtual models from the global list
type(vdcptrtype), dimension(:), pointer all_exchanges => null()
 all virtual exchanges from the global list
type(vdcptrtype), dimension(:), pointer rte_models => null()
 the currently active models to be routed
type(vdcptrtype), dimension(:), pointer rte_exchanges => null()
 the currently active exchanges to be routed
type(mpimessagebuildertype) message_builder
type(mpimessagecachetype) msg_cache
type(mpiworldtype), pointer mpi_world => null()
integer(i4b) imon
 the output file unit for the mpi monitor
logical(lgp) enable_monitor
 when true, log diagnostics
integer(i4b), dimension(:, :), allocatable tmr_mpi_wait
 array with timer handles for MPI_Wait calls
logical(lgp) halo_activated
 when true, the halo has been activated
integer(i4b) nr_virt_solutions
 number of virtual solution to be routed (allowing more efficient routing of virtual data)

Private Member Functions

procedure, private activate (this, models, exchanges)
 Activate models and exchanges for routing.
procedure, private deactivate (this)
 Deactivate data after routing.
procedure, private update_senders (this)
procedure, private update_receivers (this)
procedure, private route_active (this, unit, stage)
 Routes the models and exchanges over MPI, either constructing the message bodies in a sequence of communication steps, or by loading from cache.
procedure, private is_cached (this, unit, stage)
 Check if this stage is cached.
procedure, private compose_messages (this, unit, stage, body_snd_t, body_rcv_t)
 Constructs the message bodies' MPI datatypes.
procedure, private load_messages (this, unit, stage, body_snd_t, body_rcv_t)
 Load the message body MPI datatypes from cache.

Detailed Description

Definition at line 23 of file MpiRouter.f90.

Member Function/Subroutine Documentation

◆ activate()

procedure, private mpiroutermodule::mpiroutertype::activate ( class(mpiroutertype) this,
type(vdcptrtype), dimension(:), pointer models,
type(vdcptrtype), dimension(:), pointer exchanges )
private

Definition at line 44 of file MpiRouter.f90.

◆ compose_messages()

procedure, private mpiroutermodule::mpiroutertype::compose_messages ( class(mpiroutertype) this,
integer(i4b) unit,
integer(i4b) stage,
integer, dimension(:) body_snd_t,
integer, dimension(:) body_rcv_t )
private

Constructs the message bodies' MPI datatypes for a unit (a solution) and a given stage. This is done in a sequence of 6 steps (distributed over 3 phases):

== synchronizing headers (VdcHeaderType) ==

step 1: Receive headers from remote addresses requesting data from virtual data containers (models, exchanges, ...) local to this process step 2: Send headers to remote addresses to indicate for which virtual data containers (models, exchanges, ...) data is requested

== synchronizing maps (VdcReceiverMapsType) ==

step 3: Based on the received headers, receive element maps (which elements are to be sent from a contiguous array) for outgoing data step 4: Send element maps to remote addresses to specify incoming data

== construct message body data types (VirtualDataContainerType) ==

step 5: Construct the message receive body based on the virtual data items in the virtual data containers, and cache

step 6: Construct the message send body, based on received header data and and maps, from the virtual data containers, and cache

Definition at line 50 of file MpiRouter.f90.

◆ deactivate()

procedure, private mpiroutermodule::mpiroutertype::deactivate ( class(mpiroutertype) this)
private

Definition at line 45 of file MpiRouter.f90.

◆ destroy() [1/2]

procedure mpiroutermodule::mpiroutertype::destroy ( class(mpiroutertype) this)

Definition at line 42 of file MpiRouter.f90.

◆ destroy() [2/2]

procedure(destroy_if), deferred routerbasemodule::routerbasetype::destroy ( class(routerbasetype) this)
pure virtualinherited

Definition at line 16 of file RouterBase.f90.

◆ finalize() [1/2]

procedure mpiroutermodule::mpiroutertype::finalize ( class(mpiroutertype) this)

Definition at line 41 of file MpiRouter.f90.

◆ finalize() [2/2]

procedure(finalize_if), deferred routerbasemodule::routerbasetype::finalize ( class(routerbasetype) this)
pure virtualinherited

Definition at line 15 of file RouterBase.f90.

◆ initialize() [1/2]

procedure mpiroutermodule::mpiroutertype::initialize ( class(mpiroutertype) this)

Definition at line 38 of file MpiRouter.f90.

◆ initialize() [2/2]

procedure(initialize_if), deferred routerbasemodule::routerbasetype::initialize ( class(routerbasetype) this)
pure virtualinherited

Definition at line 12 of file RouterBase.f90.

◆ is_cached()

procedure, private mpiroutermodule::mpiroutertype::is_cached ( class(mpiroutertype) this,
integer(i4b) unit,
integer(i4b) stage )
private

Definition at line 49 of file MpiRouter.f90.

◆ load_messages()

procedure, private mpiroutermodule::mpiroutertype::load_messages ( class(mpiroutertype) this,
integer(i4b) unit,
integer(i4b) stage,
integer, dimension(:), allocatable body_snd_t,
integer, dimension(:), allocatable body_rcv_t )
private

Definition at line 51 of file MpiRouter.f90.

◆ route_active()

procedure, private mpiroutermodule::mpiroutertype::route_active ( class(mpiroutertype) this,
integer(i4b) unit,
integer(i4b) stage )
private
Parameters
thisthis mpi router
unitthe solution id, or equal to 0 when global
stagethe stage to route

Definition at line 48 of file MpiRouter.f90.

◆ route_all() [1/2]

procedure mpiroutermodule::mpiroutertype::route_all ( class(mpiroutertype) this,
integer(i4b) stage )

Definition at line 39 of file MpiRouter.f90.

◆ route_all() [2/2]

procedure(route_all_if), deferred routerbasemodule::routerbasetype::route_all ( class(routerbasetype) this,
integer(i4b) stage )
pure virtualinherited

Definition at line 13 of file RouterBase.f90.

◆ route_sln() [1/2]

procedure mpiroutermodule::mpiroutertype::route_sln ( class(mpiroutertype) this,
type(virtualsolutiontype) virtual_sol,
integer(i4b) stage )

Definition at line 40 of file MpiRouter.f90.

◆ route_sln() [2/2]

procedure(route_sln_if), deferred routerbasemodule::routerbasetype::route_sln ( class(routerbasetype) this,
type(virtualsolutiontype) virtual_sol,
integer(i4b) stage )
pure virtualinherited

Definition at line 14 of file RouterBase.f90.

◆ update_receivers()

procedure, private mpiroutermodule::mpiroutertype::update_receivers ( class(mpiroutertype) this)
private

Definition at line 47 of file MpiRouter.f90.

◆ update_senders()

procedure, private mpiroutermodule::mpiroutertype::update_senders ( class(mpiroutertype) this)
private

Definition at line 46 of file MpiRouter.f90.

Member Data Documentation

◆ all_exchanges

type(vdcptrtype), dimension(:), pointer mpiroutermodule::mpiroutertype::all_exchanges => null()

Definition at line 28 of file MpiRouter.f90.

◆ all_models

type(vdcptrtype), dimension(:), pointer mpiroutermodule::mpiroutertype::all_models => null()

Definition at line 27 of file MpiRouter.f90.

◆ enable_monitor

logical(lgp) mpiroutermodule::mpiroutertype::enable_monitor

Definition at line 35 of file MpiRouter.f90.

35 logical(LGP) :: enable_monitor !< when true, log diagnostics

◆ halo_activated

logical(lgp) routerbasemodule::routerbasetype::halo_activated
inherited

Definition at line 8 of file RouterBase.f90.

8 logical(LGP) :: halo_activated !< when true, the halo has been activated

◆ imon

integer(i4b) mpiroutermodule::mpiroutertype::imon

Definition at line 34 of file MpiRouter.f90.

34 integer(I4B) :: imon !< the output file unit for the mpi monitor

◆ message_builder

type(mpimessagebuildertype) mpiroutermodule::mpiroutertype::message_builder

Definition at line 31 of file MpiRouter.f90.

31 type(MpiMessageBuilderType) :: message_builder

◆ model_proc_ids

integer(i4b), dimension(:), pointer mpiroutermodule::mpiroutertype::model_proc_ids

Definition at line 24 of file MpiRouter.f90.

24 integer(I4B), dimension(:), pointer :: model_proc_ids

◆ mpi_world

type(mpiworldtype), pointer mpiroutermodule::mpiroutertype::mpi_world => null()

Definition at line 33 of file MpiRouter.f90.

◆ msg_cache

type(mpimessagecachetype) mpiroutermodule::mpiroutertype::msg_cache

Definition at line 32 of file MpiRouter.f90.

32 type(MpiMessageCacheType) :: msg_cache

◆ nr_virt_solutions

integer(i4b) routerbasemodule::routerbasetype::nr_virt_solutions
inherited

Definition at line 9 of file RouterBase.f90.

9 integer(I4B) :: nr_virt_solutions !< number of virtual solution to be routed

◆ receivers

type(stlvecint) mpiroutermodule::mpiroutertype::receivers

Definition at line 26 of file MpiRouter.f90.

26 type(STLVecInt) :: receivers !< the process ids to send data to

◆ rte_exchanges

type(vdcptrtype), dimension(:), pointer mpiroutermodule::mpiroutertype::rte_exchanges => null()

Definition at line 30 of file MpiRouter.f90.

◆ rte_models

type(vdcptrtype), dimension(:), pointer mpiroutermodule::mpiroutertype::rte_models => null()

Definition at line 29 of file MpiRouter.f90.

◆ senders

type(stlvecint) mpiroutermodule::mpiroutertype::senders

Definition at line 25 of file MpiRouter.f90.

25 type(STLVecInt) :: senders !< the process ids to receive data from

◆ tmr_mpi_wait

integer(i4b), dimension(:, :), allocatable mpiroutermodule::mpiroutertype::tmr_mpi_wait

Definition at line 36 of file MpiRouter.f90.

36 integer(I4B), dimension(:, :), allocatable :: tmr_mpi_wait !< array with timer handles for MPI_Wait calls

The documentation for this type was generated from the following file:
  • /home/runner/work/modflow6/modflow6/src/Distributed/MpiRouter.f90