dtfft_config Module

Configuration module for dtFFT. It handles both runtime (environment variables) and compile-time (dtfft_config_t) configurations.


Uses

  • module~~dtfft_config~~UsesGraph module~dtfft_config dtfft_config iso_c_binding iso_c_binding module~dtfft_config->iso_c_binding iso_fortran_env iso_fortran_env module~dtfft_config->iso_fortran_env module~dtfft_abstract_compressor dtfft_abstract_compressor module~dtfft_config->module~dtfft_abstract_compressor module~dtfft_errors dtfft_errors module~dtfft_config->module~dtfft_errors module~dtfft_interface_cuda_runtime dtfft_interface_cuda_runtime module~dtfft_config->module~dtfft_interface_cuda_runtime module~dtfft_parameters dtfft_parameters module~dtfft_config->module~dtfft_parameters module~dtfft_utils dtfft_utils module~dtfft_config->module~dtfft_utils mpi_f08 mpi_f08 module~dtfft_config->mpi_f08 module~dtfft_abstract_compressor->iso_c_binding module~dtfft_abstract_compressor->iso_fortran_env module~dtfft_abstract_compressor->module~dtfft_errors module~dtfft_abstract_compressor->module~dtfft_parameters module~dtfft_abstract_compressor->module~dtfft_utils module~dtfft_abstract_compressor->mpi_f08 module~dtfft_interface_nvtx dtfft_interface_nvtx module~dtfft_abstract_compressor->module~dtfft_interface_nvtx module~dtfft_errors->iso_fortran_env module~dtfft_interface_cuda_runtime->iso_c_binding module~dtfft_interface_cuda_runtime->iso_fortran_env module~dtfft_interface_cuda_runtime->module~dtfft_parameters module~dtfft_interface_cuda_runtime->module~dtfft_utils module~dtfft_parameters->iso_c_binding module~dtfft_parameters->iso_fortran_env module~dtfft_parameters->mpi_f08 module~dtfft_utils->iso_c_binding module~dtfft_utils->iso_fortran_env module~dtfft_utils->module~dtfft_errors module~dtfft_utils->module~dtfft_parameters module~dtfft_utils->mpi_f08 module~dtfft_interface_nvtx->iso_c_binding module~dtfft_interface_nvtx->module~dtfft_utils

Used by

  • module~~dtfft_config~~UsedByGraph module~dtfft_config dtfft_config module~dtfft dtfft module~dtfft->module~dtfft_config module~dtfft_pencil dtfft_pencil module~dtfft->module~dtfft_pencil module~dtfft_plan dtfft_plan module~dtfft->module~dtfft_plan module~dtfft_abstract_kernel dtfft_abstract_kernel module~dtfft_abstract_kernel->module~dtfft_config module~dtfft_abstract_reshape_handle dtfft_abstract_reshape_handle module~dtfft_abstract_reshape_handle->module~dtfft_config module~dtfft_abstract_reshape_handle->module~dtfft_pencil module~dtfft_abstract_backend dtfft_abstract_backend module~dtfft_abstract_reshape_handle->module~dtfft_abstract_backend module~dtfft_api dtfft_api module~dtfft_api->module~dtfft_config module~dtfft_api->module~dtfft_pencil module~dtfft_api->module~dtfft_plan module~dtfft_compressor_zfp dtfft_compressor_zfp module~dtfft_compressor_zfp->module~dtfft_config module~dtfft_executor_cufft_m dtfft_executor_cufft_m module~dtfft_executor_cufft_m->module~dtfft_config module~dtfft_abstract_executor dtfft_abstract_executor module~dtfft_executor_cufft_m->module~dtfft_abstract_executor module~dtfft_executor_vkfft_m dtfft_executor_vkfft_m module~dtfft_executor_vkfft_m->module~dtfft_config module~dtfft_executor_vkfft_m->module~dtfft_abstract_executor module~dtfft_kernel_device dtfft_kernel_device module~dtfft_kernel_device->module~dtfft_config module~dtfft_kernel_device->module~dtfft_abstract_kernel module~dtfft_nvrtc_block_optimizer dtfft_nvrtc_block_optimizer module~dtfft_kernel_device->module~dtfft_nvrtc_block_optimizer module~dtfft_nvrtc_module_cache dtfft_nvrtc_module_cache module~dtfft_kernel_device->module~dtfft_nvrtc_module_cache module~dtfft_kernel_host dtfft_kernel_host module~dtfft_kernel_host->module~dtfft_config module~dtfft_kernel_host->module~dtfft_abstract_kernel module~dtfft_nvrtc_block_optimizer->module~dtfft_config module~dtfft_nvrtc_block_optimizer->module~dtfft_abstract_kernel module~dtfft_nvrtc_module dtfft_nvrtc_module module~dtfft_nvrtc_module->module~dtfft_config module~dtfft_nvrtc_module->module~dtfft_abstract_kernel module~dtfft_nvrtc_module->module~dtfft_nvrtc_block_optimizer module~dtfft_nvrtc_module_cache->module~dtfft_config module~dtfft_nvrtc_module_cache->module~dtfft_abstract_kernel module~dtfft_nvrtc_module_cache->module~dtfft_nvrtc_block_optimizer module~dtfft_nvrtc_module_cache->module~dtfft_nvrtc_module module~dtfft_pencil->module~dtfft_config module~dtfft_plan->module~dtfft_config module~dtfft_plan->module~dtfft_executor_cufft_m module~dtfft_plan->module~dtfft_executor_vkfft_m module~dtfft_plan->module~dtfft_pencil module~dtfft_reshape_plan dtfft_reshape_plan module~dtfft_plan->module~dtfft_reshape_plan module~dtfft_transpose_plan dtfft_transpose_plan module~dtfft_plan->module~dtfft_transpose_plan module~dtfft_plan->module~dtfft_abstract_executor module~dtfft_executor_fftw_m dtfft_executor_fftw_m module~dtfft_plan->module~dtfft_executor_fftw_m module~dtfft_executor_mkl_m dtfft_executor_mkl_m module~dtfft_plan->module~dtfft_executor_mkl_m module~dtfft_reshape_handle_generic dtfft_reshape_handle_generic module~dtfft_reshape_handle_generic->module~dtfft_config module~dtfft_reshape_handle_generic->module~dtfft_abstract_kernel module~dtfft_reshape_handle_generic->module~dtfft_abstract_reshape_handle module~dtfft_reshape_handle_generic->module~dtfft_kernel_device module~dtfft_reshape_handle_generic->module~dtfft_kernel_host module~dtfft_reshape_handle_generic->module~dtfft_pencil module~dtfft_reshape_handle_generic->module~dtfft_abstract_backend module~dtfft_backend_cufftmp_m dtfft_backend_cufftmp_m module~dtfft_reshape_handle_generic->module~dtfft_backend_cufftmp_m module~dtfft_backend_mpi dtfft_backend_mpi module~dtfft_reshape_handle_generic->module~dtfft_backend_mpi module~dtfft_backend_nccl_m dtfft_backend_nccl_m module~dtfft_reshape_handle_generic->module~dtfft_backend_nccl_m module~dtfft_reshape_plan->module~dtfft_config module~dtfft_reshape_plan->module~dtfft_abstract_reshape_handle module~dtfft_reshape_plan->module~dtfft_pencil module~dtfft_reshape_plan_base dtfft_reshape_plan_base module~dtfft_reshape_plan->module~dtfft_reshape_plan_base module~dtfft_reshape_plan->module~dtfft_abstract_backend module~dtfft_reshape_plan_base->module~dtfft_config module~dtfft_reshape_plan_base->module~dtfft_abstract_reshape_handle module~dtfft_reshape_plan_base->module~dtfft_pencil module~dtfft_reshape_plan_base->module~dtfft_reshape_handle_generic module~dtfft_reshape_plan_base->module~dtfft_abstract_backend module~dtfft_reshape_handle_datatype dtfft_reshape_handle_datatype module~dtfft_reshape_plan_base->module~dtfft_reshape_handle_datatype module~dtfft_transpose_plan->module~dtfft_config module~dtfft_transpose_plan->module~dtfft_abstract_reshape_handle module~dtfft_transpose_plan->module~dtfft_pencil module~dtfft_transpose_plan->module~dtfft_reshape_plan_base module~dtfft_transpose_plan->module~dtfft_abstract_backend program~test_compression test_compression program~test_compression->module~dtfft_config program~test_compression->module~dtfft_abstract_kernel program~test_compression->module~dtfft_compressor_zfp program~test_compression->module~dtfft_kernel_host program~test_device_kernels test_device_kernels program~test_device_kernels->module~dtfft_config program~test_device_kernels->module~dtfft_abstract_kernel program~test_device_kernels->module~dtfft_kernel_device program~test_device_kernels->module~dtfft_kernel_host module~dtfft_abstract_backend->module~dtfft_abstract_kernel module~dtfft_abstract_backend->module~dtfft_pencil module~dtfft_abstract_executor->module~dtfft_pencil module~dtfft_backend_cufftmp_m->module~dtfft_pencil module~dtfft_backend_cufftmp_m->module~dtfft_abstract_backend module~dtfft_executor_fftw_m->module~dtfft_pencil module~dtfft_executor_fftw_m->module~dtfft_abstract_executor module~dtfft_reshape_handle_datatype->module~dtfft_abstract_reshape_handle module~dtfft_reshape_handle_datatype->module~dtfft_pencil program~test_host_kernels test_host_kernels program~test_host_kernels->module~dtfft_kernel_host module~dtfft_backend_mpi->module~dtfft_abstract_backend module~dtfft_backend_nccl_m->module~dtfft_abstract_backend module~dtfft_executor_mkl_m->module~dtfft_abstract_executor

Variables

Type Visibility Attributes Name Initial
logical, protected :: is_init_called = .false.

Has init_internal already been called or not

integer(kind=int32), protected :: log_enabled_from_env = VARIABLE_NOT_SET

Should we log messages to stdout or not

type(dtfft_platform_t), protected :: platform_from_env = PLATFORM_NOT_SET

Platform obtained from environ

integer(kind=int32), protected :: z_slab_from_env = VARIABLE_NOT_SET

Should Z-slab be used if possible

integer(kind=int32), protected :: y_slab_from_env = VARIABLE_NOT_SET

Should Y-slab be used if possible

integer(kind=int32), protected :: n_measure_warmup_iters_from_env = VARIABLE_NOT_SET

Number of warmup iterations for measurements

integer(kind=int32), protected :: n_measure_iters_from_env = VARIABLE_NOT_SET

Number of measurement iterations

logical, protected :: is_log_enabled = .false.

Should we print additional information during plan creation

logical, protected :: is_z_slab_enabled = .true.

Should we use Z-slab optimization or not

logical, protected :: is_y_slab_enabled = .false.

Should we use Y-slab optimization or not

type(dtfft_platform_t), protected :: platform = DTFFT_PLATFORM_HOST

Default platform

integer(kind=int32), protected :: n_measure_warmup_iters = 2

Number of warmup iterations for measurements

integer(kind=int32), protected :: n_measure_iters = 5

Number of measurement iterations

type(dtfft_backend_t), protected :: backend_from_env = DTFFT_BACKEND_NONE

Backend obtained from environ

type(dtfft_backend_t), protected :: reshape_backend_from_env = DTFFT_BACKEND_NONE

Reshape backend obtained from environ

integer(kind=int32), protected :: datatype_enabled_from_env = VARIABLE_NOT_SET

Should we use MPI Datatype backend during autotune or not

integer(kind=int32), protected :: mpi_enabled_from_env = VARIABLE_NOT_SET

Should we use MPI backends during autotune or not

integer(kind=int32), protected :: pipelined_enabled_from_env = VARIABLE_NOT_SET

Should we use pipelined backends during autotune or not

integer(kind=int32), protected :: kernel_autotune_enabled_from_env = VARIABLE_NOT_SET

Should we enable kernel autotune or not

integer(kind=int32), protected :: fourier_reshape_enabled_from_env = VARIABLE_NOT_SET

Should we enable fourier space reshape or not

integer(kind=int32), protected :: fused_enabled_from_env = VARIABLE_NOT_SET

Should we use fused backends during autotune or not

type(dtfft_transpose_mode_t), protected :: transpose_mode_from_env = TRANSPOSE_MODE_NOT_SET

Transpose mode obtained from environ

type(dtfft_access_mode_t), protected :: access_mode_from_env = ACCESS_MODE_NOT_SET

Access mode obtained from environ

integer(kind=int32), protected :: compression_enabled_from_env = VARIABLE_NOT_SET

Should we use compressed backends during autotune or not

integer(kind=int32), protected :: nccl_enabled_from_env = VARIABLE_NOT_SET

Should we use NCCL backends during autotune or not

integer(kind=int32), protected :: nvshmem_enabled_from_env = VARIABLE_NOT_SET

Should we use NVSHMEM backends during autotune or not

type(dtfft_stream_t), protected :: main_stream = NULL_STREAM

Default dtFFT CUDA stream

type(dtfft_stream_t), protected :: custom_stream = NULL_STREAM

CUDA stream set by the user

logical, protected :: is_stream_created = .false.

Is the default stream created?

logical, protected :: is_custom_stream = .false.

Is the custom stream provided by the user?

logical, protected :: is_datatype_enabled = .true.

Should we use MPI Datatype backend or not

logical, protected :: is_pipelined_enabled = .true.

Should we use pipelined backends or not

logical, protected :: is_mpi_enabled = .false.

Should we use MPI backends or not

logical, protected :: is_nccl_enabled = .true.

Should we use NCCL backends or not

logical, protected :: is_nvshmem_enabled = .true.

Should we use NCCL backends or not

logical, protected :: is_kernel_autotune_enabled = .false.

Should we use kernel autotune or not

logical, protected :: is_fourier_reshape_enabled = .false.

Should we use reshape in fourier space or not

logical, protected :: is_rma_enabled = .true.

Should we use RMA backends or not

logical, protected :: is_fused_enabled = .true.

Should we use fused backends or not

type(dtfft_backend_t), protected :: backend = DEFAULT_BACKEND

Default backend

type(dtfft_backend_t), protected :: reshape_backend = DEFAULT_BACKEND

Default reshape backend

type(dtfft_transpose_mode_t), protected :: transpose_mode = DTFFT_TRANSPOSE_MODE_PACK

Default transpose mode

type(dtfft_access_mode_t), protected :: access_mode = DTFFT_ACCESS_MODE_WRITE

Default access mode

logical, protected :: is_compression_enabled = .false.

Should we use compressed backends or not during autotuning

type(dtfft_compression_config_t), protected :: config_transpose = DEFAULT_COMPRESSION_CONFIG

Configuration for compression during transpositions

type(dtfft_compression_config_t), protected :: config_reshape = DEFAULT_COMPRESSION_CONFIG

Configuration for compression during reshape operations

type(dtfft_backend_t), private, parameter :: DEFAULT_BACKEND = DTFFT_BACKEND_NONE

Default backend when cuda is enabled


Interfaces

public interface dtfft_config_t

Interface to create a new configuration

  • private pure function config_constructor(enable_log, enable_z_slab, enable_y_slab, n_measure_warmup_iters, n_measure_iters, platform, stream, backend, reshape_backend, enable_datatype_backend, enable_mpi_backends, enable_pipelined_backends, enable_rma_backends, enable_fused_backends, enable_nccl_backends, enable_nvshmem_backends, enable_kernel_autotune, enable_fourier_reshape, transpose_mode, access_mode, enable_compressed_backends, compression_config_transpose, compression_config_reshape) result(config)

    Creates a new configuration

    Arguments

    Type IntentOptional Attributes Name
    logical, intent(in), optional :: enable_log

    Should dtFFT print additional information during plan creation or not.

    logical, intent(in), optional :: enable_z_slab

    Should dtFFT use Z-slab optimization or not.

    logical, intent(in), optional :: enable_y_slab

    Should dtFFT use Y-slab optimization or not.

    integer(kind=int32), intent(in), optional :: n_measure_warmup_iters

    Number of warmup iterations for measurements

    integer(kind=int32), intent(in), optional :: n_measure_iters

    Number of measurement iterations

    type(dtfft_platform_t), intent(in), optional :: platform

    Selects platform to execute plan.

    type(dtfft_stream_t), intent(in), optional :: stream

    Main CUDA stream that will be used in dtFFT.

    type(dtfft_backend_t), intent(in), optional :: backend

    Backend that will be used by dtFFT when effort is DTFFT_ESTIMATE or DTFFT_MEASURE.

    type(dtfft_backend_t), intent(in), optional :: reshape_backend

    Backend that will be used by dtFFT for data reshaping from bricks to pencils and vice versa when effort is DTFFT_ESTIMATE or DTFFT_MEASURE.

    logical, intent(in), optional :: enable_datatype_backend

    Should DTFFT_BACKEND_MPI_DATATYPE be enabled when effort is DTFFT_PATIENT or not.

    logical, intent(in), optional :: enable_mpi_backends

    Should MPI Backends be enabled when effort is DTFFT_PATIENT or not.

    logical, intent(in), optional :: enable_pipelined_backends

    Should pipelined backends be enabled when effort is DTFFT_PATIENT or not.

    logical, intent(in), optional :: enable_rma_backends

    Should RMA backends be enabled when effort is DTFFT_PATIENT or not.

    logical, intent(in), optional :: enable_fused_backends

    Should fused backends be enabled when effort is DTFFT_PATIENT or not.

    logical, intent(in), optional :: enable_nccl_backends

    Should NCCL Backends be enabled when effort is DTFFT_PATIENT or not.

    logical, intent(in), optional :: enable_nvshmem_backends

    Should NVSHMEM Backends be enabled when effort is DTFFT_PATIENT or not.

    logical, intent(in), optional :: enable_kernel_autotune

    Should dtFFT try to autotune transpose/packing/unpacking kernels size during autotune process or not.

    logical, intent(in), optional :: enable_fourier_reshape

    Should dtFFT execute reshapes from pencils to bricks and vice versa in Fourier space during calls to execute or not.

    type(dtfft_transpose_mode_t), intent(in), optional :: transpose_mode

    Specifies at which stage the local transposition is performed during global exchange.

    type(dtfft_access_mode_t), intent(in), optional :: access_mode

    Specifies the memory access pattern (optimization target) for local transposition in Generic backends.

    logical, intent(in), optional :: enable_compressed_backends

    Should compressed backends be enabled when effort is DTFFT_PATIENT or DTFFT_EXHAUSTIVE.

    type(dtfft_compression_config_t), intent(in), optional :: compression_config_transpose

    Options for compression approach during transpositions

    type(dtfft_compression_config_t), intent(in), optional :: compression_config_reshape

    Options for compression approach during transpositions

    Return Value type(dtfft_config_t)

    Constructed dtFFT config ready to be set by call to dtfft_set_config

private interface get_conf_internal

Returns value from configuration unless environment variable is set

  • private elemental function get_conf_internal_logical(from_conf, from_env)

    Returns value from configuration unless environment variable is set

    Arguments

    Type IntentOptional Attributes Name
    logical, intent(in) :: from_conf

    Value from configuration

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

    Value from environment variable

    Return Value logical

  • private elemental function get_conf_internal_int32(from_conf, from_env)

    Returns value from configuration unless environment variable is set

    Arguments

    Type IntentOptional Attributes Name
    integer(kind=int32), intent(in) :: from_conf

    Value from configuration

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

    Value from environment variable

    Return Value integer(kind=int32)


Derived Types

type, public, bind(C) ::  dtfft_config_t

Type that can be used to set additional configuration parameters to dtFFT

Components

Type Visibility Attributes Name Initial
logical(kind=c_bool), public :: enable_log

Should dtFFT print additional information during plan creation or not.

Read more…
logical(kind=c_bool), public :: enable_z_slab

Should dtFFT use Z-slab optimization or not.

Read more…
logical(kind=c_bool), public :: enable_y_slab

Should dtFFT use Y-slab optimization or not.

Read more…
integer(kind=c_int32_t), public :: n_measure_warmup_iters

Number of warmup iterations to execute during backend and kernel autotuning when effort level is DTFFT_MEASURE or higher.

Read more…
integer(kind=c_int32_t), public :: n_measure_iters

Number of iterations to execute during backend and kernel autotuning when effort level is DTFFT_MEASURE or higher.

Read more…
type(dtfft_platform_t), public :: platform

Selects platform to execute plan.

Read more…
type(dtfft_stream_t), public :: stream

Main CUDA stream that will be used in dtFFT.

Read more…
type(dtfft_backend_t), public :: backend

Backend that will be used by dtFFT when effort is DTFFT_ESTIMATE or DTFFT_MEASURE.

Read more…
type(dtfft_backend_t), public :: reshape_backend

Backend that will be used by dtFFT for data reshaping from bricks to pencils and vice versa when effort is DTFFT_ESTIMATE or DTFFT_MEASURE.

Read more…
logical(kind=c_bool), public :: enable_datatype_backend

Should DTFFT_BACKEND_MPI_DATATYPE be considered for autotuning when effort is DTFFT_PATIENT or DTFFT_EXHAUSTIVE.

Read more…
logical(kind=c_bool), public :: enable_mpi_backends

Should MPI Backends be enabled when effort is DTFFT_PATIENT or DTFFT_EXHAUSTIVE.

Read more…
logical(kind=c_bool), public :: enable_pipelined_backends

Should pipelined backends be enabled when effort is DTFFT_PATIENT or DTFFT_EXHAUSTIVE.

Read more…
logical(kind=c_bool), public :: enable_rma_backends

Should RMA backends be enabled when effort is DTFFT_PATIENT or DTFFT_EXHAUSTIVE.

Read more…
logical(kind=c_bool), public :: enable_fused_backends

Should fused backends be enabled when effort is DTFFT_PATIENT or DTFFT_EXHAUSTIVE.

Read more…
logical(kind=c_bool), public :: enable_nccl_backends

Should NCCL Backends be enabled when effort is DTFFT_PATIENT or DTFFT_EXHAUSTIVE.

Read more…
logical(kind=c_bool), public :: enable_nvshmem_backends

Should NVSHMEM Backends be enabled when effort is DTFFT_PATIENT or DTFFT_EXHAUSTIVE.

Read more…
logical(kind=c_bool), public :: enable_kernel_autotune

Should dtFFT try to optimize kernel launch parameters during plan creation when effort is below DTFFT_EXHAUSTIVE.

Read more…
logical(kind=c_bool), public :: enable_fourier_reshape

Should dtFFT execute reshapes from pencils to bricks and vice versa in Fourier space during calls to execute.

Read more…
type(dtfft_transpose_mode_t), public :: transpose_mode

Specifies at which stage the local transposition is performed during global exchange.

Read more…
type(dtfft_access_mode_t), public :: access_mode

Specifies the memory access pattern (optimization target) for local transposition.

Read more…
logical(kind=c_bool), public :: enable_compressed_backends

Should compressed backends be enabled when effort is DTFFT_PATIENT or DTFFT_EXHAUSTIVE.

Read more…
type(dtfft_compression_config_t), public :: compression_config_transpose

Options for compression approach during transpositions

type(dtfft_compression_config_t), public :: compression_config_reshape

Options for compression approach during reshape operations

Constructor

Interface to create a new configuration

private pure function config_constructor (enable_log, enable_z_slab, enable_y_slab, n_measure_warmup_iters, n_measure_iters, platform, stream, backend, reshape_backend, enable_datatype_backend, enable_mpi_backends, enable_pipelined_backends, enable_rma_backends, enable_fused_backends, enable_nccl_backends, enable_nvshmem_backends, enable_kernel_autotune, enable_fourier_reshape, transpose_mode, access_mode, enable_compressed_backends, compression_config_transpose, compression_config_reshape)

Creates a new configuration


Functions

public function init_internal()

Checks if MPI is initialized and loads environment variables

Arguments

None

Return Value integer(kind=int32)

public elemental function get_correct_backend(back)

Arguments

Type IntentOptional Attributes Name
type(dtfft_backend_t), intent(in) :: back

Return Value type(dtfft_backend_t)

public elemental function get_conf_log_enabled() result(bool)

Whether logging is enabled or not

Arguments

None

Return Value logical

Result flag

public elemental function get_conf_z_slab_enabled() result(bool)

Whether Z-slab optimization is enabled or not

Arguments

None

Return Value logical

Result flag

public elemental function get_conf_y_slab_enabled() result(bool)

Whether Y-slab optimization is enabled or not

Arguments

None

Return Value logical

Result flag

public elemental function get_conf_measure_warmup_iters() result(iters)

Returns the number of warmup iterations

Arguments

None

Return Value integer(kind=int32)

Result

public elemental function get_conf_measure_iters() result(iters)

Returns the number of measurement iterations

Arguments

None

Return Value integer(kind=int32)

Result

public elemental function get_conf_platform()

Returns platform set by the user or default one

Arguments

None

Return Value type(dtfft_platform_t)

public function get_conf_stream() result(stream)

Returns either the custom provided by user or creates a new one

Arguments

None

Return Value type(dtfft_stream_t)

public elemental function get_conf_backend()

Returns backend set by the user or default one

Arguments

None

Return Value type(dtfft_backend_t)

public elemental function get_conf_reshape_backend()

Returns reshape backend set by the user or default one

Arguments

None

Return Value type(dtfft_backend_t)

public elemental function get_conf_datatype_enabled() result(bool)

Whether MPI Datatype backend is enabled or not

Arguments

None

Return Value logical

Result flag

public elemental function get_conf_pipelined_enabled() result(bool)

Whether pipelined backends are enabled or not

Arguments

None

Return Value logical

Result flag

public elemental function get_conf_rma_enabled() result(bool)

Whether RMA backends are enabled or not

Arguments

None

Return Value logical

Result flag

public elemental function get_conf_fused_enabled() result(bool)

Whether fused backends are enabled or not

Arguments

None

Return Value logical

Result flag

public elemental function get_conf_mpi_enabled() result(bool)

Whether MPI backends are enabled or not

Arguments

None

Return Value logical

Result flag

public elemental function get_conf_nccl_enabled() result(bool)

Whether NCCL backends are enabled or not

Arguments

None

Return Value logical

Result flag

public elemental function get_conf_nvshmem_enabled() result(bool)

Whether nvshmem backends are enabled or not

Arguments

None

Return Value logical

Result flag

public elemental function get_conf_kernel_autotune_enabled() result(bool)

Whether kernel optimization is enabled or not

Arguments

None

Return Value logical

Result flag

public elemental function get_conf_fourier_reshape_enabled() result(bool)

Whether reshape in Fourier space is enabled or not

Arguments

None

Return Value logical

Result flag

public elemental function get_conf_transpose_mode() result(mode)

Returns transpose mode set by the user or default one

Arguments

None

Return Value type(dtfft_transpose_mode_t)

Result

public elemental function get_conf_access_mode() result(mode)

Returns access mode set by the user or default one

Arguments

None

Return Value type(dtfft_access_mode_t)

Result

public elemental function get_conf_compression_enabled() result(bool)

Whether compression is enabled or not

Arguments

None

Return Value logical

Result flag

public elemental function get_conf_transpose() result(config)

Returns compression config for transposes

Arguments

None

Return Value type(dtfft_compression_config_t)

Result

public elemental function get_conf_reshape() result(config)

Returns compression config for reshapes

Arguments

None

Return Value type(dtfft_compression_config_t)

Result

private function get_backend_from_env(name)

Returns backend or reshape backend obtained from environment variable

Arguments

Type IntentOptional Attributes Name
character(len=*), intent(in) :: name

Name of the environment variable

Return Value type(dtfft_backend_t)

private pure function config_constructor(enable_log, enable_z_slab, enable_y_slab, n_measure_warmup_iters, n_measure_iters, platform, stream, backend, reshape_backend, enable_datatype_backend, enable_mpi_backends, enable_pipelined_backends, enable_rma_backends, enable_fused_backends, enable_nccl_backends, enable_nvshmem_backends, enable_kernel_autotune, enable_fourier_reshape, transpose_mode, access_mode, enable_compressed_backends, compression_config_transpose, compression_config_reshape) result(config)

Creates a new configuration

Arguments

Type IntentOptional Attributes Name
logical, intent(in), optional :: enable_log

Should dtFFT print additional information during plan creation or not.

logical, intent(in), optional :: enable_z_slab

Should dtFFT use Z-slab optimization or not.

logical, intent(in), optional :: enable_y_slab

Should dtFFT use Y-slab optimization or not.

integer(kind=int32), intent(in), optional :: n_measure_warmup_iters

Number of warmup iterations for measurements

integer(kind=int32), intent(in), optional :: n_measure_iters

Number of measurement iterations

type(dtfft_platform_t), intent(in), optional :: platform

Selects platform to execute plan.

type(dtfft_stream_t), intent(in), optional :: stream

Main CUDA stream that will be used in dtFFT.

type(dtfft_backend_t), intent(in), optional :: backend

Backend that will be used by dtFFT when effort is DTFFT_ESTIMATE or DTFFT_MEASURE.

type(dtfft_backend_t), intent(in), optional :: reshape_backend

Backend that will be used by dtFFT for data reshaping from bricks to pencils and vice versa when effort is DTFFT_ESTIMATE or DTFFT_MEASURE.

logical, intent(in), optional :: enable_datatype_backend

Should DTFFT_BACKEND_MPI_DATATYPE be enabled when effort is DTFFT_PATIENT or not.

logical, intent(in), optional :: enable_mpi_backends

Should MPI Backends be enabled when effort is DTFFT_PATIENT or not.

logical, intent(in), optional :: enable_pipelined_backends

Should pipelined backends be enabled when effort is DTFFT_PATIENT or not.

logical, intent(in), optional :: enable_rma_backends

Should RMA backends be enabled when effort is DTFFT_PATIENT or not.

logical, intent(in), optional :: enable_fused_backends

Should fused backends be enabled when effort is DTFFT_PATIENT or not.

logical, intent(in), optional :: enable_nccl_backends

Should NCCL Backends be enabled when effort is DTFFT_PATIENT or not.

logical, intent(in), optional :: enable_nvshmem_backends

Should NVSHMEM Backends be enabled when effort is DTFFT_PATIENT or not.

logical, intent(in), optional :: enable_kernel_autotune

Should dtFFT try to autotune transpose/packing/unpacking kernels size during autotune process or not.

logical, intent(in), optional :: enable_fourier_reshape

Should dtFFT execute reshapes from pencils to bricks and vice versa in Fourier space during calls to execute or not.

type(dtfft_transpose_mode_t), intent(in), optional :: transpose_mode

Specifies at which stage the local transposition is performed during global exchange.

type(dtfft_access_mode_t), intent(in), optional :: access_mode

Specifies the memory access pattern (optimization target) for local transposition in Generic backends.

logical, intent(in), optional :: enable_compressed_backends

Should compressed backends be enabled when effort is DTFFT_PATIENT or DTFFT_EXHAUSTIVE.

type(dtfft_compression_config_t), intent(in), optional :: compression_config_transpose

Options for compression approach during transpositions

type(dtfft_compression_config_t), intent(in), optional :: compression_config_reshape

Options for compression approach during transpositions

Return Value type(dtfft_config_t)

Constructed dtFFT config ready to be set by call to dtfft_set_config

private elemental function get_conf_internal_logical(from_conf, from_env)

Returns value from configuration unless environment variable is set

Arguments

Type IntentOptional Attributes Name
logical, intent(in) :: from_conf

Value from configuration

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

Value from environment variable

Return Value logical

private elemental function get_conf_internal_int32(from_conf, from_env)

Returns value from configuration unless environment variable is set

Arguments

Type IntentOptional Attributes Name
integer(kind=int32), intent(in) :: from_conf

Value from configuration

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

Value from environment variable

Return Value integer(kind=int32)


Subroutines

public pure subroutine dtfft_create_config(config) bind(C, name="dtfft_create_config_c")

Creates a new configuration and sets default values.

Read more…

Arguments

Type IntentOptional Attributes Name
type(dtfft_config_t), intent(out) :: config

Configuration to create

public subroutine dtfft_set_config(config, error_code)

Sets configuration parameters

Arguments

Type IntentOptional Attributes Name
type(dtfft_config_t), intent(in) :: config

Configuration to set

integer(kind=int32), intent(out), optional :: error_code

Error code

public subroutine destroy_stream()

Destroy the default stream if it was created

Arguments

None

private subroutine init_environment()

Arguments

None