Show / Hide Table of Contents

Class cufft

cufft wrapper Complete documentation here

Inheritance
System.Object
cufft
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: Hybridizer.Runtime.CUDAImports
Assembly: Hybridizer.Runtime.CUDAImports.dll
Syntax
public class cufft

Methods

Create(out cufftHandle)

Creates only an opaque handle, and allocates small data structures on the host online

Declaration
public static cufftResult Create(out cufftHandle plan)
Parameters
Type Name Description
cufftHandle plan

Pointer to a cufftHandle object

Returns
Type Description
cufftResult

Destroy(cufftHandle)

onlone

Declaration
public static cufftResult Destroy(cufftHandle plan)
Parameters
Type Name Description
cufftHandle plan
Returns
Type Description
cufftResult

Estimate1d(Int32, cufftType, Int32, out size_t)

During plan execution, cuFFT requires a work area for temporary storage of intermediate results. This call returns an estimate for the size of the work area required, given the specified parameters, and assuming default plan settings. online

Declaration
public static cufftResult Estimate1d(int nx, cufftType type, int batch, out size_t workSize)
Parameters
Type Name Description
System.Int32 nx

The transform size in the x dimension (number of rows)

cufftType type

The transform data type (e.g., CUFFT_C2R for single precision complex to real)

System.Int32 batch

Number of transforms of size nx. Please consider using EstimateMany(Int32, Int32[], Int32[], Int32, Int32, Int32[], Int32, Int32, cufftType, Int32, out size_t) for multiple transforms.

size_t workSize

Pointer to the size, in bytes, of the work space.

Returns
Type Description
cufftResult

Estimate2d(Int32, Int32, cufftType, out size_t)

During plan execution, cuFFT requires a work area for temporary storage of intermediate results. This call returns an estimate for the size of the work area required, given the specified parameters, and assuming default plan settings.

Declaration
public static cufftResult Estimate2d(int nx, int ny, cufftType type, out size_t workSize)
Parameters
Type Name Description
System.Int32 nx

The transform size in the x dimension (number of rows)

System.Int32 ny

The transform size in the y dimension (number of columns)

cufftType type

The transform data type (e.g., CUFFT_C2R for single precision complex to real)

size_t workSize

Pointer to the size, in bytes, of the work space.

Returns
Type Description
cufftResult

Estimate3d(Int32, Int32, Int32, cufftType, out size_t)

During plan execution, cuFFT requires a work area for temporary storage of intermediate results. This call returns an estimate for the size of the work area required, given the specified parameters, and assuming default plan settings.

Declaration
public static cufftResult Estimate3d(int nx, int ny, int nz, cufftType type, out size_t workSize)
Parameters
Type Name Description
System.Int32 nx

The transform size in the x dimension

System.Int32 ny

The transform size in the y dimension

System.Int32 nz

The transform size in the z dimension

cufftType type

The transform data type (e.g., CUFFT_C2R for single precision complex to real)

size_t workSize

Pointer to the size, in bytes, of the work space.

Returns
Type Description
cufftResult

EstimateMany(Int32, Int32[], Int32[], Int32, Int32, Int32[], Int32, Int32, cufftType, Int32, out size_t)

During plan execution, cuFFT requires a work area for temporary storage of intermediate results. This call returns an estimate for the size of the work area required, given the specified parameters, and assuming default plan settings. The cufftEstimateMany() API supports more complicated input and output data layouts via the advanced data layout parameters: inembed, istride, idist, onembed, ostride, and odist. All arrays are assumed to be in CPU memory.

Declaration
public static cufftResult EstimateMany(int rank, int[] n, int[] inembed, int istride, int idist, int[] onembed, int ostride, int odist, cufftType type, int batch, out size_t workSize)
Parameters
Type Name Description
System.Int32 rank

Dimensionality of the transform (1, 2, or 3)

System.Int32[] n

Array of size rank, describing the size of each dimension

System.Int32[] inembed

Pointer of size rank that indicates the storage dimensions of the input data in memory. If set to NULL all other advanced data layout parameters are ignored.

System.Int32 istride

Indicates the distance between two successive input elements in the least significant (i.e., innermost) dimension

System.Int32 idist

Indicates the distance between the first element of two consecutive signals in a batch of the input data

System.Int32[] onembed

Pointer of size rank that indicates the storage dimensions of the output data in memory. If set to NULL all other advanced data layout parameters are ignored.

System.Int32 ostride

Indicates the distance between two successive output elements in the output array in the least significant (i.e., innermost) dimension

System.Int32 odist

Indicates the distance between the first element of two consecutive signals in a batch of the output data

cufftType type

The transform data type (e.g., CUFFT_R2C for single precision real to complex)

System.Int32 batch

Batch size for this transform

size_t workSize

Pointer to the size, in bytes, of the work space.

Returns
Type Description
cufftResult

ExecC2C(cufftHandle, float2[], float2[], Int32)

online

Declaration
public static cufftResult ExecC2C(cufftHandle plan, float2[] idata, float2[] odata, int direction)
Parameters
Type Name Description
cufftHandle plan
float2[] idata
float2[] odata
System.Int32 direction
Returns
Type Description
cufftResult

ExecC2C(cufftHandle, IntPtr, IntPtr, Int32)

online

Declaration
public static cufftResult ExecC2C(cufftHandle plan, IntPtr idata, IntPtr odata, int direction)
Parameters
Type Name Description
cufftHandle plan
System.IntPtr idata
System.IntPtr odata
System.Int32 direction
Returns
Type Description
cufftResult

ExecC2C<C>(cufftHandle, C[], C[], Int32)

online

Declaration
public static cufftResult ExecC2C<C>(cufftHandle plan, C[] idata, C[] odata, int direction)
Parameters
Type Name Description
cufftHandle plan
C[] idata
C[] odata
System.Int32 direction
Returns
Type Description
cufftResult
Type Parameters
Name Description
C

ExecC2R(cufftHandle, float2[], Single[])

online

Declaration
public static cufftResult ExecC2R(cufftHandle plan, float2[] idata, float[] odata)
Parameters
Type Name Description
cufftHandle plan
float2[] idata
System.Single[] odata
Returns
Type Description
cufftResult

ExecC2R(cufftHandle, IntPtr, IntPtr)

online

Declaration
public static cufftResult ExecC2R(cufftHandle plan, IntPtr idata, IntPtr odata)
Parameters
Type Name Description
cufftHandle plan
System.IntPtr idata
System.IntPtr odata
Returns
Type Description
cufftResult

ExecC2R<R, C>(cufftHandle, C[], R[])

float type

Declaration
public static cufftResult ExecC2R<R, C>(cufftHandle plan, C[] idata, R[] odata)
Parameters
Type Name Description
cufftHandle plan
C[] idata
R[] odata
Returns
Type Description
cufftResult
Type Parameters
Name Description
R
C

ExecD2Z(cufftHandle, IntPtr, IntPtr)

online

Declaration
public static cufftResult ExecD2Z(cufftHandle plan, IntPtr idata, IntPtr odata)
Parameters
Type Name Description
cufftHandle plan
System.IntPtr idata
System.IntPtr odata
Returns
Type Description
cufftResult

ExecR2C(cufftHandle, IntPtr, IntPtr)

online

Declaration
public static cufftResult ExecR2C(cufftHandle plan, IntPtr idata, IntPtr odata)
Parameters
Type Name Description
cufftHandle plan
System.IntPtr idata
System.IntPtr odata
Returns
Type Description
cufftResult

ExecR2C(cufftHandle, Single[], float2[])

online

Declaration
public static cufftResult ExecR2C(cufftHandle plan, float[] idata, float2[] odata)
Parameters
Type Name Description
cufftHandle plan
System.Single[] idata
float2[] odata
Returns
Type Description
cufftResult

ExecR2C<R, C>(cufftHandle, R[], C[])

float type

Declaration
public static cufftResult ExecR2C<R, C>(cufftHandle plan, R[] idata, C[] odata)
Parameters
Type Name Description
cufftHandle plan
R[] idata
C[] odata
Returns
Type Description
cufftResult
Type Parameters
Name Description
R
C

ExecZ2D(cufftHandle, IntPtr, IntPtr)

online

Declaration
public static cufftResult ExecZ2D(cufftHandle plan, IntPtr idata, IntPtr odata)
Parameters
Type Name Description
cufftHandle plan
System.IntPtr idata
System.IntPtr odata
Returns
Type Description
cufftResult

ExecZ2Z(cufftHandle, IntPtr, IntPtr, Int32)

online

Declaration
public static cufftResult ExecZ2Z(cufftHandle plan, IntPtr idata, IntPtr odata, int direction)
Parameters
Type Name Description
cufftHandle plan
System.IntPtr idata
System.IntPtr odata
System.Int32 direction
Returns
Type Description
cufftResult

GetProperty(libraryPropertyType_t, out Int32)

Return in *value the number for the property described by type of the dynamically linked CUFFT library.

Declaration
public static cufftResult GetProperty(libraryPropertyType_t type, out int val)
Parameters
Type Name Description
libraryPropertyType_t type

CUDA library property

System.Int32 val

Contains the integer value for the requested property

Returns
Type Description
cufftResult

GetSize(cufftHandle, out size_t)

Once plan generation has been done, either with the original API or the extensible API, this call returns the actual size of the work area required to support the plan. Callers who choose to manage work area allocation within their application must use this call after plan generation, and after any cufftSet*() calls subsequent to plan generation, if those calls might alter the required work space size.

Declaration
public static cufftResult GetSize(cufftHandle handle, out size_t workSize)
Parameters
Type Name Description
cufftHandle handle

cufftHandle returned by Create(out cufftHandle)

size_t workSize

Pointer to the size(s), in bytes, of the work areas. For example for two GPUs worksize must be declared to have two elements.

Returns
Type Description
cufftResult

GetSize1d(cufftHandle, Int32, cufftType, Int32, out size_t)

Gives a more accurate estimate of the work area size required for a plan than the Estimate1d(Int32, cufftType, Int32, out size_t) routine as they take into account any plan settings that may have been made. As discussed in the section cuFFT Estimated Size of Work Area, the workSize value(s) returned may be conservative especially for values of n that are not multiples of powers of 2, 3, 5 and 7.

Declaration
public static cufftResult GetSize1d(cufftHandle handle, int nx, cufftType type, int batch, out size_t workSize)
Parameters
Type Name Description
cufftHandle handle

cufftHandle returned by cufftCreate

System.Int32 nx

The transform size (e.g. 256 for a 256-point FFT)

cufftType type

The transform data type (e.g., CUFFT_C2C for single precision complex to complex)

System.Int32 batch

Number of transforms of size nx. Please consider using cufftGetSizeMany for multiple transforms.

size_t workSize

Pointer to the size(s), in bytes, of the work areas. For example for two GPUs worksize must be declared to have two elements.

Returns
Type Description
cufftResult

GetSize2d(cufftHandle, Int32, Int32, cufftType, out size_t)

This call gives a more accurate estimate of the work area size required for a plan than Estimate2d(Int32, Int32, cufftType, out size_t), given the specified parameters, and taking into account any plan settings that may have been made.

Declaration
public static cufftResult GetSize2d(cufftHandle handle, int nx, int ny, cufftType type, out size_t workSize)
Parameters
Type Name Description
cufftHandle handle

cufftHandle returned by cufftCreate

System.Int32 nx

The transform size in the x dimension (number of rows)

System.Int32 ny

The transform size in the y dimension (number of columns)

cufftType type

The transform data type (e.g., CUFFT_C2R for single precision complex to real)

size_t workSize

Pointer to the size(s), in bytes, of the work areas. For example for two GPUs worksize must be declared to have two elements.

Returns
Type Description
cufftResult

GetSize3d(cufftHandle, Int32, Int32, Int32, cufftType, out size_t)

This call gives a more accurate estimate of the work area size required for a plan than Estimate3d(Int32, Int32, Int32, cufftType, out size_t), given the specified parameters, and taking into account any plan settings that may have been made.

Declaration
public static cufftResult GetSize3d(cufftHandle handle, int nx, int ny, int nz, cufftType type, out size_t workSize)
Parameters
Type Name Description
cufftHandle handle

cufftHandle returned by cufftCreate

System.Int32 nx

The transform size in the x dimension

System.Int32 ny

The transform size in the y dimension

System.Int32 nz

The transform size in the z dimension

cufftType type

The transform data type (e.g., CUFFT_R2C for single precision real to complex)

size_t workSize

Pointer to the size(s), in bytes, of the work areas. For example for two GPUs worksize must be declared to have two elements.

Returns
Type Description
cufftResult

GetSizeMany(cufftHandle, Int32, Int32[], Int32[], Int32, Int32, Int32[], Int32, Int32, cufftType, Int32, out size_t)

This call gives a more accurate estimate of the work area size required for a plan than EstimateMany(Int32, Int32[], Int32[], Int32, Int32, Int32[], Int32, Int32, cufftType, Int32, out size_t), given the specified parameters, and taking into account any plan settings that may have been made.

Declaration
public static cufftResult GetSizeMany(cufftHandle plan, int rank, int[] n, int[] inembed, int istride, int idist, int[] onembed, int ostride, int odist, cufftType type, int batch, out size_t workSize)
Parameters
Type Name Description
cufftHandle plan

cufftHandle returned by cufftCreate

System.Int32 rank

Dimensionality of the transform (1, 2, or 3)

System.Int32[] n

Array of size rank, describing the size of each dimension

System.Int32[] inembed

Pointer of size rank that indicates the storage dimensions of the input data in memory. If set to NULL all other advanced data layout parameters are ignored.

System.Int32 istride

Indicates the distance between two successive input elements in the least significant (i.e., innermost) dimension

System.Int32 idist

Indicates the distance between the first element of two consecutive signals in a batch of the input data

System.Int32[] onembed

Pointer of size rank that indicates the storage dimensions of the output data in memory. If set to NULL all other advanced data layout parameters are ignored.

System.Int32 ostride

Indicates the distance between two successive output elements in the output array in the least significant (i.e., innermost) dimension

System.Int32 odist

Indicates the distance between the first element of two consecutive signals in a batch of the output data

cufftType type

The transform data type (e.g., CUFFT_R2C for single precision real to complex)

System.Int32 batch

Batch size for this transform

size_t workSize

Pointer to the size(s), in bytes, of the work areas. For example for two GPUs worksize must be declared to have two elements.

Returns
Type Description
cufftResult

GetSizeMany64(cufftHandle, Int32, Int64[], Int64[], Int64, Int64, Int64[], Int64, Int64, cufftType, Int64, out size_t)

This call gives a more accurate estimate of the work area size required for a plan than cufftEstimateSizeMany(), given the specified parameters, and taking into account any plan settings that may have been made. This API is identical to cufftMakePlanMany except that the arguments specifying sizes and strides are 64 bit integers.This API makes very large transforms possible. cuFFT includes kernels that use 32 bit indexes, and kernels that use 64 bit indexes. cuFFT planning selects 32 bit kernels whenever possible to avoid any overhead due to 64 bit arithmetic. All sizes and types of transform are supported by this interface, with two exceptions.For transforms whose total size exceeds 4G elements, the dimensions specified in the array n must be factorable into primes that are less than or equal to 127. For real to complex and complex to real transforms whose total size exceeds 2G elements, the fastest changing dimension must be even.

Declaration
public static cufftResult GetSizeMany64(cufftHandle plan, int rank, long[] n, long[] inembed, long istride, long idist, long[] onembed, long ostride, long odist, cufftType type, long batch, out size_t workSize)
Parameters
Type Name Description
cufftHandle plan

cufftHandle returned by cufftCreate

System.Int32 rank

Dimensionality of the transform (1, 2, or 3)

System.Int64[] n

Array of size rank, describing the size of each dimension

System.Int64[] inembed

Pointer of size rank that indicates the storage dimensions of the input data in memory. If set to NULL all other advanced data layout parameters are ignored.

System.Int64 istride

Indicates the distance between two successive input elements in the least significant (i.e., innermost) dimension

System.Int64 idist

Indicates the distance between the first element of two consecutive signals in a batch of the input data

System.Int64[] onembed

Pointer of size rank that indicates the storage dimensions of the output data in memory. If set to NULL all other advanced data layout parameters are ignored.

System.Int64 ostride

Indicates the distance between two successive output elements in the output array in the least significant (i.e., innermost) dimension

System.Int64 odist

Indicates the distance between the first element of two consecutive signals in a batch of the output data

cufftType type

The transform data type (e.g., CUFFT_R2C for single precision real to complex)

System.Int64 batch

Batch size for this transform

size_t workSize

Pointer to the size(s), in bytes, of the work areas. For example for two GPUs worksize must be declared to have two elements.

Returns
Type Description
cufftResult

GetVersion(out Int32)

Returns the version number of cuFFT.

Declaration
public static cufftResult GetVersion(out int version)
Parameters
Type Name Description
System.Int32 version

Pointer to the version number

Returns
Type Description
cufftResult

MakePlan1d(cufftHandle, Int32, cufftType, Int32, out size_t)

Following a call to cufftCreate() makes a 1D FFT plan configuration for a specified signal size and data type. The batch input parameter tells cuFFT how many 1D transforms to configure. If cufftXtSetGPUs() was called prior to this call with multiple GPUs, then workSize will contain multiple sizes. See sections on multiple GPUs for more details.

Declaration
public static cufftResult MakePlan1d(cufftHandle plan, int nx, cufftType type, int batch, out size_t workSize)
Parameters
Type Name Description
cufftHandle plan

cufftHandle returned by cufftCreate

System.Int32 nx

The transform size (e.g. 256 for a 256-point FFT). For multiple GPUs, this must be a power of 2.

cufftType type

The transform data type (e.g., CUFFT_C2C for single precision complex to complex). For multiple GPUs this must be a complex to complex transform.

System.Int32 batch

Number of transforms of size nx. Please consider using cufftMakePlanMany for multiple transforms.

size_t workSize

Pointer to the size(s), in bytes, of the work areas. For example for two GPUs worksize must be declared to have two elements.

Returns
Type Description
cufftResult

MakePlan2d(cufftHandle, Int32, Int32, cufftType, out size_t)

Following a call to cufftCreate() makes a 2D FFT plan configuration according to specified signal sizes and data type. If cufftXtSetGPUs() was called prior to this call with multiple GPUs, then workSize will contain multiple sizes. See sections on multiple GPUs for more details.

Declaration
public static cufftResult MakePlan2d(cufftHandle plan, int nx, int ny, cufftType type, out size_t workSize)
Parameters
Type Name Description
cufftHandle plan

cufftHandle returned by cufftCreate

System.Int32 nx

The transform size in the x dimension. This is slowest changing dimension of a transform (strided in memory). For multiple GPUs, this must be factorable into primes less than or equal to 127.

System.Int32 ny

The transform size in the y dimension. This is fastest changing dimension of a transform (contiguous in memory). For 2 GPUs, this must be factorable into primes less than or equal to 127.

cufftType type

The transform data type (e.g., CUFFT_C2R for single precision complex to real). For multiple GPUs this must be a complex to complex transform.

size_t workSize

Pointer to the size(s), in bytes, of the work areas. For example for two GPUs worksize must be declared to have two elements.

Returns
Type Description
cufftResult

MakePlan3d(cufftHandle, Int32, Int32, Int32, cufftType, out size_t)

Following a call to cufftCreate() makes a 3D FFT plan configuration according to specified signal sizes and data type. This function is the same as cufftPlan2d() except that it takes a third size parameter nz. If cufftXtSetGPUs() was called prior to this call with multiple GPUs, then workSize will contain multiple sizes. See sections on multiple GPUs for more details.

Declaration
public static cufftResult MakePlan3d(cufftHandle plan, int nx, int ny, int nz, cufftType type, out size_t workSize)
Parameters
Type Name Description
cufftHandle plan

cufftHandle returned by cufftCreate

System.Int32 nx

The transform size in the x dimension. This is slowest changing dimension of a transform (strided in memory). For multiple GPUs, this must be factorable into primes less than or equal to 127.

System.Int32 ny

The transform size in the y dimension. For multiple GPUs, this must be factorable into primes less than or equal to 127.

System.Int32 nz

The transform size in the z dimension. This is fastest changing dimension of a transform (contiguous in memory). For multiple GPUs, this must be factorable into primes less than or equal to 127.

cufftType type

The transform data type (e.g., CUFFT_R2C for single precision real to complex). For multiple GPUs this must be a complex to complex transform.

size_t workSize

Pointer to the size(s), in bytes, of the work areas. For example for two GPUs worksize must be declared to have two elements.

Returns
Type Description
cufftResult

MakePlanMany(cufftHandle, Int32, Int32[], Int32[], Int32, Int32, Int32[], Int32, Int32, cufftType, Int32, out size_t)

Following a call to cufftCreate() makes a FFT plan configuration of dimension rank, with sizes specified in the array n. The batch input parameter tells cuFFT how many transforms to configure. With this function, batched plans of 1, 2, or 3 dimensions may be created. The cufftPlanMany() API supports more complicated input and output data layouts via the advanced data layout parameters: inembed, istride, idist, onembed, ostride, and odist. If inembed and onembed are set to NULL, all other stride information is ignored, and default strides are used. The default assumes contiguous data arrays. If cufftXtSetGPUs() was called prior to this call with multiple GPUs, then workSize will contain multiple sizes. See sections on multiple GPUs for more details. All arrays are assumed to be in CPU memory.

Declaration
public static cufftResult MakePlanMany(cufftHandle plan, int rank, int[] n, int[] inembed, int istride, int idist, int[] onembed, int ostride, int odist, cufftType type, int batch, out size_t workSize)
Parameters
Type Name Description
cufftHandle plan

cufftHandle returned by cufftCreate

System.Int32 rank

Dimensionality of the transform (1, 2, or 3)

System.Int32[] n

Array of size rank, describing the size of each dimension, n[0] being the size of the outermost and n[rank-1] innermost (contiguous) dimension of a transform. For multiple GPUs and rank equal to 1, the sizes must be a power of 2. For multiple GPUs and rank equal to 2 or 3, the sizes must be factorable into primes less than or equal to 127.

System.Int32[] inembed

Pointer of size rank that indicates the storage dimensions of the input data in memory, inembed[0] being the storage dimension of the innermost dimension. If set to NULL all other advanced data layout parameters are ignored.

System.Int32 istride

Indicates the distance between two successive input elements in the least significant (i.e., innermost) dimension

System.Int32 idist

Indicates the distance between the first element of two consecutive signals in a batch of the input data

System.Int32[] onembed

Pointer of size rank that indicates the storage dimensions of the output data in memory, inembed[0] being the storage dimension of the innermost dimension. If set to NULL all other advanced data layout parameters are ignored.

System.Int32 ostride

Indicates the distance between two successive output elements in the output array in the least significant (i.e., innermost) dimension

System.Int32 odist

Indicates the distance between the first element of two consecutive signals in a batch of the output data

cufftType type

The transform data type (e.g., CUFFT_R2C for single precision real to complex). For 2 GPUs this must be a complex to complex transform.

System.Int32 batch

Batch size for this transform

size_t workSize

Pointer to the size(s), in bytes, of the work areas. For example for two GPUs worksize must be declared to have two elements.

Returns
Type Description
cufftResult

MakePlanMany64(cufftHandle, Int32, Int64[], Int64[], Int64, Int64, Int64[], Int64, Int64, cufftType, Int64, out size_t)

Following a call to cufftCreate() makes a FFT plan configuration of dimension rank, with sizes specified in the array n. The batch input parameter tells cuFFT how many transforms to configure. With this function, batched plans of 1, 2, or 3 dimensions may be created. The cufftPlanMany() API supports more complicated input and output data layouts via the advanced data layout parameters: inembed, istride, idist, onembed, ostride, and odist. If inembed and onembed are set to NULL, all other stride information is ignored, and default strides are used. The default assumes contiguous data arrays. If cufftXtSetGPUs() was called prior to this call with multiple GPUs, then workSize will contain multiple sizes. See sections on multiple GPUs for more details. All arrays are assumed to be in CPU memory.

Declaration
public static cufftResult MakePlanMany64(cufftHandle plan, int rank, long[] n, long[] inembed, long istride, long idist, long[] onembed, long ostride, long odist, cufftType type, long batch, out size_t workSize)
Parameters
Type Name Description
cufftHandle plan

cufftHandle returned by cufftCreate

System.Int32 rank

Dimensionality of the transform (1, 2, or 3)

System.Int64[] n

Array of size rank, describing the size of each dimension, n[0] being the size of the outermost and n[rank-1] innermost (contiguous) dimension of a transform. For multiple GPUs and rank equal to 1, the sizes must be a power of 2. For multiple GPUs and rank equal to 2 or 3, the sizes must be factorable into primes less than or equal to 127.

System.Int64[] inembed

Pointer of size rank that indicates the storage dimensions of the input data in memory, inembed[0] being the storage dimension of the innermost dimension. If set to NULL all other advanced data layout parameters are ignored.

System.Int64 istride

Indicates the distance between two successive input elements in the least significant (i.e., innermost) dimension

System.Int64 idist

Indicates the distance between the first element of two consecutive signals in a batch of the input data

System.Int64[] onembed

Pointer of size rank that indicates the storage dimensions of the output data in memory, inembed[0] being the storage dimension of the innermost dimension. If set to NULL all other advanced data layout parameters are ignored.

System.Int64 ostride

Indicates the distance between two successive output elements in the output array in the least significant (i.e., innermost) dimension

System.Int64 odist

Indicates the distance between the first element of two consecutive signals in a batch of the output data

cufftType type

The transform data type (e.g., CUFFT_R2C for single precision real to complex). For 2 GPUs this must be a complex to complex transform.

System.Int64 batch

Batch size for this transform

size_t workSize

Pointer to the size(s), in bytes, of the work areas. For example for two GPUs worksize must be declared to have two elements.

Returns
Type Description
cufftResult

Plan1d(out cufftHandle, Int32, cufftType, Int32)

online

Declaration
public static cufftResult Plan1d(out cufftHandle plan, int nx, cufftType type, int batch)
Parameters
Type Name Description
cufftHandle plan
System.Int32 nx
cufftType type
System.Int32 batch
Returns
Type Description
cufftResult

Plan2d(out cufftHandle, Int32, Int32, cufftType)

online

Declaration
public static cufftResult Plan2d(out cufftHandle plan, int nx, int ny, cufftType type)
Parameters
Type Name Description
cufftHandle plan
System.Int32 nx
System.Int32 ny
cufftType type
Returns
Type Description
cufftResult

Plan3d(out cufftHandle, Int32, Int32, Int32, cufftType)

online

Declaration
public static cufftResult Plan3d(out cufftHandle plan, int nx, int ny, int nz, cufftType type)
Parameters
Type Name Description
cufftHandle plan
System.Int32 nx
System.Int32 ny
System.Int32 nz
cufftType type
Returns
Type Description
cufftResult

PlanMany(out cufftHandle, Int32, Int32[], Int32[], Int32, Int32, Int32[], Int32, Int32, cufftType, Int32)

online

Declaration
public static cufftResult PlanMany(out cufftHandle plan, int rank, int[] n, int[] inembed, int istride, int idist, int[] onembed, int ostride, int odist, cufftType type, int batch)
Parameters
Type Name Description
cufftHandle plan
System.Int32 rank
System.Int32[] n
System.Int32[] inembed
System.Int32 istride
System.Int32 idist
System.Int32[] onembed
System.Int32 ostride
System.Int32 odist
cufftType type
System.Int32 batch
Returns
Type Description
cufftResult

PlanMany(out cufftHandle, Int32, IntPtr, IntPtr, Int32, Int32, IntPtr, Int32, Int32, cufftType, Int32)

online

Declaration
public static cufftResult PlanMany(out cufftHandle plan, int rank, IntPtr n, IntPtr inembed, int istride, int idist, IntPtr onembed, int ostride, int odist, cufftType type, int batch)
Parameters
Type Name Description
cufftHandle plan
System.Int32 rank
System.IntPtr n
System.IntPtr inembed
System.Int32 istride
System.Int32 idist
System.IntPtr onembed
System.Int32 ostride
System.Int32 odist
cufftType type
System.Int32 batch
Returns
Type Description
cufftResult

SetAutoAllocate(cufftHandle, Int32)

cufftSetAutoAllocation() indicates that the caller intends to allocate and manage work areas for plans that have been generated. cuFFT default behavior is to allocate the work area at plan generation time. If cufftSetAutoAllocation() has been called with autoAllocate set to 0 ("false") prior to one of the cufftMakePlan*() calls, cuFFT does not allocate the work area. This is the preferred sequence for callers wishing to manage work area allocation.

Declaration
public static cufftResult SetAutoAllocate(cufftHandle plan, int autoAllocate)
Parameters
Type Name Description
cufftHandle plan

cufftHandle returned by cufftCreate.

System.Int32 autoAllocate

allocate

Returns
Type Description
cufftResult

SetCompatibilityMode(cufftHandle, cufftCompatibility)

online

Declaration
public static cufftResult SetCompatibilityMode(cufftHandle plan, cufftCompatibility mode)
Parameters
Type Name Description
cufftHandle plan
cufftCompatibility mode
Returns
Type Description
cufftResult

SetStream(cufftHandle, cudaStream_t)

online

Declaration
public static cufftResult SetStream(cufftHandle plan, cudaStream_t stream)
Parameters
Type Name Description
cufftHandle plan
cudaStream_t stream
Returns
Type Description
cufftResult

SetWorkArea(cufftHandle, IntPtr)

cufftSetWorkArea() overrides the work area pointer associated with a plan. If the work area was auto-allocated, cuFFT frees the auto-allocated space. The cufftExecute*() calls assume that the work area pointer is valid and that it points to a contiguous region in device memory that does not overlap with any other work area. If this is not the case, results are indeterminate.

Declaration
public static cufftResult SetWorkArea(cufftHandle plan, IntPtr workArea)
Parameters
Type Name Description
cufftHandle plan

cufftHandle returned by cufftCreate

System.IntPtr workArea

Pointer to workArea. For multiple GPUs, multiple work area pointers must be given.

Returns
Type Description
cufftResult

XtMakePlanMany(cufftHandle, Int32, Int64[], Int64[], Int64, Int64, cudaDataType_t, Int64[], Int64, Int64, cudaDataType_t, Int64, out size_t, cudaDataType_t)

Following a call to cufftCreate() makes an FFT plan configuration of dimension rank, with sizes specified in the array n. The batch input parameter tells cuFFT how many transforms to configure. With this function, batched plans of 1, 2, or 3 dimensions may be created. Type specifiers inputtype, outputtype and executiontype dictate type and precision of transform to be performed. Not all combinations of parameters are supported. Currently all three parameters need to match precision. Parameters inputtype and outputtype need to match transform type complex-to-complex, real-to-complex or complex-to-real. Parameter executiontype needs to match precision and be of a complex type. Example: for a 16 bit real-to-complex transform parameters inputtype, outputtype and executiontype would have values of CUDA_R_16F, CUDA_C_16F and CUDA_C_16F respectively. The cufftXtMakePlanMany() API supports more complicated input and output data layouts via the advanced data layout parameters: inembed, istride, idist, onembed, ostride, and odist. If inembed and onembed are set to NULL, all other stride information is ignored, and default strides are used. The default assumes contiguous data arrays. If cufftXtSetGPUs() was called prior to this call with multiple GPUs, then workSize will contain multiple sizes. See sections on multiple GPUs for more details. All arrays are assumed to be in CPU memory.

Declaration
public static cufftResult XtMakePlanMany(cufftHandle plan, int rank, long[] n, long[] inembed, long istride, long idist, cudaDataType_t inputtype, long[] onembed, long ostride, long odist, cudaDataType_t outputtype, long batch, out size_t workSize, cudaDataType_t executiontype)
Parameters
Type Name Description
cufftHandle plan

cufftHandle returned by cufftCreate

System.Int32 rank

Dimensionality of the transform (1, 2, or 3)

System.Int64[] n

Array of size rank, describing the size of each dimension, n[0] being the size of the innermost deminsion. For multiple GPUs and rank equal to 1, the sizes must be a power of 2. For multiple GPUs and rank equal to 2 or 3, the sizes must be factorable into primes less than or equal to 127.

System.Int64[] inembed

Pointer of size rank that indicates the storage dimensions of the input data in memory, inembed[0] being the storage dimension of the innermost dimension. If set to NULL all other advanced data layout parameters are ignored.

System.Int64 istride

Indicates the distance between two successive input elements in the least significant (i.e., innermost) dimension

System.Int64 idist

Indicates the distance between the first element of two consecutive signals in a batch of the input data

cudaDataType_t inputtype

Type of input data.

System.Int64[] onembed

Pointer of size rank that indicates the storage dimensions of the output data in memory, inembed[0] being the storage dimension of the innermost dimension. If set to NULL all other advanced data layout parameters are ignored.

System.Int64 ostride

Indicates the distance between two successive output elements in the output array in the least significant (i.e., innermost) dimension

System.Int64 odist

Indicates the distance between the first element of two consecutive signals in a batch of the output data

cudaDataType_t outputtype

Type of output data.

System.Int64 batch

Batch size for this transform

size_t workSize

Pointer to the size(s), in bytes, of the work areas. For example for two GPUs worksize must be declared to have two elements.

cudaDataType_t executiontype

Type of data to be used for computations.

Returns
Type Description
cufftResult
Back to top Generated by DocFX