backend_helper Derived Type

type, public :: backend_helper

Helper with nccl, mpi and nvshmem communicators


Inherits

type~~backend_helper~~InheritsGraph type~backend_helper backend_helper MPI_Comm MPI_Comm type~backend_helper->MPI_Comm comms c_ptr c_ptr type~backend_helper->c_ptr nccl_register type~dtfft_transpose_t dtfft_transpose_t type~backend_helper->type~dtfft_transpose_t tranpose_type type~ncclcomm ncclComm type~backend_helper->type~ncclcomm nccl_comm type~pencil pencil type~backend_helper->type~pencil pencils type~ncclcomm->c_ptr member

Inherited by

type~~backend_helper~~InheritedByGraph type~backend_helper backend_helper type~abstract_transpose_plan abstract_transpose_plan type~abstract_transpose_plan->type~backend_helper helper type~dtfft_plan_t dtfft_plan_t type~dtfft_plan_t->type~abstract_transpose_plan plan type~transpose_plan_cuda transpose_plan_cuda type~transpose_plan_cuda->type~abstract_transpose_plan type~transpose_plan_host transpose_plan_host type~transpose_plan_host->type~abstract_transpose_plan type~dtfft_core_c2c dtfft_core_c2c type~dtfft_core_c2c->type~dtfft_plan_t type~dtfft_plan_r2r_t dtfft_plan_r2r_t type~dtfft_plan_r2r_t->type~dtfft_plan_t type~plan_c plan_c type~plan_c->type~dtfft_plan_t p type~dtfft_plan_c2c_t dtfft_plan_c2c_t type~dtfft_plan_c2c_t->type~dtfft_core_c2c type~dtfft_plan_r2c_t dtfft_plan_r2c_t type~dtfft_plan_r2c_t->type~dtfft_core_c2c

Components

Type Visibility Attributes Name Initial
logical, public :: is_nccl_created = .false.

Flag is nccl_comm has been created

type(ncclComm), public :: nccl_comm

NCCL communicator

logical, public :: should_register

If NCCL buffer should be registered

type(c_ptr), public, allocatable :: nccl_register(:,:)

NCCL register cache

integer(kind=int32), public :: nccl_register_size

Number of elements in nccl_register

type(MPI_Comm), public, allocatable :: comms(:)

MPI communicators

integer(kind=int32), public, allocatable :: comm_mappings(:,:)

Mapping of 1d comm ranks to global comm

type(dtfft_transpose_t), public :: tranpose_type

Type of transpose to create

type(pencil), public, pointer :: pencils(:)

Pencils


Type-Bound Procedures

procedure, public, pass(self) :: create => create_helper

Creates helper

  • private subroutine create_helper(self, base_comm, comms, is_nccl_needed, pencils)

    Creates helper

    Arguments

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

    Backend helper

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

    MPI communicator

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

    1D Communicators

    logical, intent(in) :: is_nccl_needed

    If nccl communicator will be needed

    type(pencil), intent(in), target :: pencils(:)

    Pencils

procedure, public, pass(self) :: destroy => destroy_helper

Destroys helper

  • private subroutine destroy_helper(self)

    Destroys helper

    Arguments

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

    Backend helper