transpose_handle_host Derived Type

type, public :: transpose_handle_host

Transposition class


Inherits

type~~transpose_handle_host~~InheritsGraph type~transpose_handle_host transpose_handle_host MPI_Comm MPI_Comm type~transpose_handle_host->MPI_Comm comm MPI_Request MPI_Request type~transpose_handle_host->MPI_Request request type~handle_t handle_t type~transpose_handle_host->type~handle_t send, recv MPI_Datatype MPI_Datatype type~handle_t->MPI_Datatype dtypes

Inherited by

type~~transpose_handle_host~~InheritedByGraph type~transpose_handle_host transpose_handle_host type~transpose_plan_host transpose_plan_host type~transpose_plan_host->type~transpose_handle_host fplans, bplans

Components

Type Visibility Attributes Name Initial
type(MPI_Comm), private :: comm

1d communicator

logical, private :: is_even

Is decomposition even

type(handle_t), private :: send

Handle to send data

type(handle_t), private :: recv

Handle to recieve data

type(MPI_Request), private :: request

Request for persistent communication

logical, private :: is_request_created

Is request created


Type-Bound Procedures

procedure, public, pass(self) :: create

Initializes class

  • private subroutine create(self, comm, send, recv, base_type, base_storage, datatype_id)

    Creates transpose_handle_host class

    Arguments

    Type IntentOptional Attributes Name
    class(transpose_handle_host), intent(inout) :: self

    Transposition class

    type(MPI_Comm), intent(in) :: comm

    1d communicator

    class(pencil), intent(in) :: send

    Information about send buffer

    class(pencil), intent(in) :: recv

    Information about recv buffer

    type(MPI_Datatype), intent(in) :: base_type

    Base MPI Datatype

    integer(kind=int64), intent(in) :: base_storage

    Number of bytes needed to store single element

    integer(kind=int8), intent(in) :: datatype_id

    Type of datatype to use

procedure, public, pass(self) :: execute

Performs MPI_Alltoall(w)

  • private subroutine execute(self, send, recv)

    Executes transposition

    Arguments

    Type IntentOptional Attributes Name
    class(transpose_handle_host), intent(inout) :: self

    Transposition class

    real(kind=real32), intent(in) :: send(:)

    Incoming buffer

    real(kind=real32), intent(inout) :: recv(:)

    Resulting buffer

procedure, public, pass(self) :: destroy

Destroys class

  • private subroutine destroy(self)

    Destroys transpose_handle_host class

    Arguments

    Type IntentOptional Attributes Name
    class(transpose_handle_host), intent(inout) :: self

    Transposition class

procedure, private, pass(self) :: create_transpose_2d

Creates two-dimensional transposition datatypes

  • private subroutine create_transpose_2d(self, n_neighbors, i, send, send_counts, recv, recv_counts, datatype_id, base_type, base_storage)

    Creates two-dimensional transposition datatypes

    Arguments

    Type IntentOptional Attributes Name
    class(transpose_handle_host), intent(inout) :: self

    Transposition class

    integer(kind=int32), intent(in) :: n_neighbors

    Size of 1d comm

    integer(kind=int32), intent(in) :: i

    Counter

    class(pencil), intent(in) :: send

    Information about send buffer

    integer(kind=int32), intent(in) :: send_counts(:)

    Rank i is sending this counts

    class(pencil), intent(in) :: recv

    Information about send buffer

    integer(kind=int32), intent(in) :: recv_counts(:)

    Rank i is recieving this counts

    integer(kind=int8), intent(in) :: datatype_id

    Id of transpose plan to use

    type(MPI_Datatype), intent(in) :: base_type

    Base MPI_Datatype

    integer(kind=int64), intent(in) :: base_storage

    Number of bytes needed to store single element

procedure, private, pass(self) :: create_transpose_XY

Creates three-dimensional X –> Y, Y –> X transposition datatypes

  • private subroutine create_transpose_XY(self, n_neighbors, i, send, send_counts, recv, recv_counts, datatype_id, base_type, base_storage)

    Creates three-dimensional X –> Y, Y –> X transposition datatypes

    Arguments

    Type IntentOptional Attributes Name
    class(transpose_handle_host), intent(inout) :: self

    Transposition class

    integer(kind=int32), intent(in) :: n_neighbors

    Size of 1d comm

    integer(kind=int32), intent(in) :: i

    Counter

    class(pencil), intent(in) :: send

    Information about send buffer

    integer(kind=int32), intent(in) :: send_counts(:)

    Rank i is sending this counts

    class(pencil), intent(in) :: recv

    Information about send buffer

    integer(kind=int32), intent(in) :: recv_counts(:)

    Rank i is recieving this counts

    integer(kind=int8), intent(in) :: datatype_id

    Id of transpose plan to use

    type(MPI_Datatype), intent(in) :: base_type

    Base MPI_Datatype

    integer(kind=int64), intent(in) :: base_storage

    Number of bytes needed to store single element

procedure, private, pass(self) :: create_transpose_YZ

Creates three-dimensional Y –> Z, Z –> Y transposition datatypes

  • private subroutine create_transpose_YZ(self, n_neighbors, i, send, send_counts, recv, recv_counts, datatype_id, base_type, base_storage)

    Creates three-dimensional Y –> Z, Z –> Y transposition datatypes

    Arguments

    Type IntentOptional Attributes Name
    class(transpose_handle_host), intent(inout) :: self

    Transposition class

    integer(kind=int32), intent(in) :: n_neighbors

    Size of 1d comm

    integer(kind=int32), intent(in) :: i

    Counter

    class(pencil), intent(in) :: send

    Information about send buffer

    integer(kind=int32), intent(in) :: send_counts(:)

    Rank i is sending this counts

    class(pencil), intent(in) :: recv

    Information about send buffer

    integer(kind=int32), intent(in) :: recv_counts(:)

    Rank i is recieving this counts

    integer(kind=int8), intent(in) :: datatype_id

    Id of transpose plan to use

    type(MPI_Datatype), intent(in) :: base_type

    Base MPI_Datatype

    integer(kind=int64), intent(in) :: base_storage

    Number of bytes needed to store single element

procedure, private, pass(self) :: create_transpose_XZ

Creates three-dimensional X –> Z datatype, only slab!

  • private subroutine create_transpose_XZ(self, n_neighbors, i, send, send_counts, recv, recv_counts, datatype_id, base_type, base_storage)

    Creates three-dimensional X –> Z transposition datatypes Can only be used with 3D slab decomposition when slabs are distributed in Z direction

    Arguments

    Type IntentOptional Attributes Name
    class(transpose_handle_host), intent(inout) :: self

    Transposition class

    integer(kind=int32), intent(in) :: n_neighbors

    Size of 1d comm

    integer(kind=int32), intent(in) :: i

    Counter

    class(pencil), intent(in) :: send

    Information about send buffer

    integer(kind=int32), intent(in) :: send_counts(:)

    Rank i is sending this counts

    class(pencil), intent(in) :: recv

    Information about send buffer

    integer(kind=int32), intent(in) :: recv_counts(:)

    Rank i is recieving this counts

    integer(kind=int8), intent(in) :: datatype_id

    Id of transpose plan to use

    type(MPI_Datatype), intent(in) :: base_type

    Base MPI_Datatype

    integer(kind=int64), intent(in) :: base_storage

    Number of bytes needed to store single element

procedure, private, pass(self) :: create_transpose_ZX

Creates three-dimensional Z –> X datatype, only slab!

  • private subroutine create_transpose_ZX(self, n_neighbors, i, send, send_counts, recv, recv_counts, datatype_id, base_type, base_storage)

    Creates three-dimensional Z –> X transposition datatypes Can only be used with 3D slab decomposition when slabs are distributed in Z direction

    Arguments

    Type IntentOptional Attributes Name
    class(transpose_handle_host), intent(inout) :: self

    Transposition class

    integer(kind=int32), intent(in) :: n_neighbors

    Size of 1d comm

    integer(kind=int32), intent(in) :: i

    Counter

    class(pencil), intent(in) :: send

    Information about send buffer

    integer(kind=int32), intent(in) :: send_counts(:)

    Rank i is sending this counts

    class(pencil), intent(in) :: recv

    Information about send buffer

    integer(kind=int32), intent(in) :: recv_counts(:)

    Rank i is recieving this counts

    integer(kind=int8), intent(in) :: datatype_id

    Id of transpose plan to use

    type(MPI_Datatype), intent(in) :: base_type

    Base MPI_Datatype

    integer(kind=int64), intent(in) :: base_storage

    Number of bytes needed to store single element