onemkl::dft::Descriptor<onemkl::dft::Precision, onemkl::dft::Domain>::setValue

Sets one particular configuration parameter with the specified configuration value.

Syntax

onemkl::dft::ErrCode setValue(onemkl::dft::ConfigParam param, ...)

Include Files

  • mkl_dfti_sycl.hpp

Description

This function sets one particular configuration parameter with the specified configuration value. Each configuration parameter is a named constant, and the configuration value must have the corresponding type, which can be a named constant or a native type. For available configuration parameters and the corresponding configuration values, see Config Params.

Note

An important addition to the configuration options for DPC++ FFT interface is onemkl::dft::FWD_DISTANCE, onemkl::dft::BWD_DISTANCE. The FWD_DISTANCE describes the distance between different FFTs for the forward domain while BWD_DISTANCE describes the distance between different FFTs for the backward domain. It is required for all R2C or C2R transforms to use FWD_DISTANCE and BWD_DISTANCE instead of INPUT_STRIDE and OUTPUT_STRIDE, respectively.

The onemkl::dft::setValue function cannot be used to change configuration parameters onemkl::dft::ConfigParam::FORWARD_DOMAIN, onemkl::dft::ConfigParam::PRECISION, DFTI_DIMENSION since these are a part of the template. Likewise, onemkl::dft::ConfigParam::LENGTHS is set with the function call onemkl::dft::Descriptor<onemkl::dft::Precision, onemkl::dft::Domain>::init.

All calls to setValue must be done after init, and before commit. This is because the handle may have been moved to an offloaded device after commit.

Function calls needed to configure an FFT descriptor for a particular call to an FFT computation function are summarized in DftiSetValue.

The function returns onemkl::dft::ErrCode::NO_ERROR when it completes successfully. See Status Checking Functions for more information on the returned status.

Input Parameters

Name

Type

Description

param

onemkl::dft::ConfigParam

Configuration parameter.

value

Depends on the configuration parameter

Configuration value.

Output Parameters

Name

Type

Description

status

onemkl::dft::ErrCode

Function completion status.

Return Values

The function returns a value indicating whether the operation was successful or not, and why.

Return Value

Description

onemkl::dft::ErrCode::NO_ERROR

The operation was successful.

onemkl::dft::ErrCode::BAD_DESCRIPTOR

DFTI handle provided is invalid.

onemkl::dft::ErrCode::INCONSISTENT_CONFIGURATION/ onemkl::dft::ErrCode::INVALID_CONFIGURATION

An input value provided is invalid.

onemkl::dft::ErrCode::UNIMPLEMENTED

Functionality requested is not implemented.