(git:e70887f)
Loading...
Searching...
No Matches
fft_gpu.h File Reference
#include <complex.h>
#include <stdbool.h>
#include <stddef.h>

Go to the source code of this file.

Functions

void fft_gpu_init (void)
 Initializes the fft_gpu library.
void fft_gpu_finalize (void)
 Releases resources held by the fft_gpu library.
void ensure_memory_sizes (const size_t requested_buffer_size, const size_t requested_map_size)
 Checks size of device buffers and re-allocates them if necessary.
void fft_gpu_allocate_double (const int length, double **buffer)
 Allocate buffer of type double.
void fft_gpu_allocate_complex (const int length, double complex **buffer)
 Allocate buffer of type double complex.
void fft_gpu_free_double (double *buffer)
 Allocate buffer of type double.
void fft_gpu_free_complex (double complex *buffer)
 Allocate buffer of type double complex.
void fft_gpu_register_1d_local (const bool dir, const int n, const int m, const bool transpose_in, const bool transpose_out, const int leading_dimension_in, const int leading_dimension_out, const bool inplace)
 Performs a (double precision complex) 1D-FFT on the GPU.
void fft_gpu_register_1d_r2c_local (const bool dir, const int n, const int m, const bool transpose_in, const bool transpose_out, const int leading_dimension_in, const int leading_dimension_out, const bool inplace)
 Performs a (double precision complex) R2C 1D-FFT on the GPU.
void fft_gpu_register_2d_local (const bool dir, const int n[2], const int m, const bool transpose_in, const bool transpose_out, const bool inplace)
 Performs a (double precision complex) 1D-FFT on the GPU.
void fft_gpu_register_2d_r2c_local (const bool dir, const int n[2], const int m, const bool transpose_in, const bool transpose_out, const bool inplace)
 Performs a (double precision complex) R2C 1D-FFT on the GPU.
void fft_gpu_register_3d_local (const bool dir, const int *npts, const bool inplace, const int number_of_ffts, const bool transpose_in, const bool transpose_out)
 Performs a (double precision complex) 3D-FFT on the GPU.
void fft_gpu_register_3d_r2c_local (const bool dir, const int *npts, const bool inplace, const int number_of_ffts, const bool transpose_in, const bool transpose_out)
 Performs a 3D-R2C/C2R-FFT, on the GPU.
void fft_gpu_1d_local (const double *zin, double *zout, const bool dir, const int n, const int m, const bool transpose_in, const bool transpose_out, const int leading_dimension_in, const int leading_dimension_out)
 Performs a (double precision complex) 1D-FFT on the GPU.
void fft_gpu_1d_r2c_local (const double *zin, double *zout, const bool dir, const int n, const int m, const bool transpose_in, const bool transpose_out, const int leading_dimension_in, const int leading_dimension_out)
 Performs a (double precision complex) R2C 1D-FFT on the GPU.
void fft_gpu_2d_local (const double *zin, double *zout, const bool dir, const int n[2], const int m, const bool transpose_in, const bool transpose_out)
 Performs a (double precision complex) 1D-FFT on the GPU.
void fft_gpu_2d_r2c_local (const double *zin, double *zout, const bool dir, const int n[2], const int m, const bool transpose_in, const bool transpose_out)
 Performs a (double precision complex) R2C 1D-FFT on the GPU.
void fft_gpu_3d_local (const double *zin, double *zout, const bool dir, const int *npts, const int number_of_ffts, const bool transpose_in, const bool transpose_out)
 Performs a (double precision complex) 3D-FFT on the GPU.
void fft_gpu_3d_r2c_local (const double *zin, double *zout, const bool dir, const int *npts, const int number_of_ffts, const bool transpose_in, const bool transpose_out)
 Performs a 3D-R2C/C2R-FFT, on the GPU.

Function Documentation

◆ fft_gpu_init()

void fft_gpu_init ( void )

Initializes the fft_gpu library.

Author
Ole Schuett

Definition at line 90 of file fft_gpu.c.

Here is the caller graph for this function:

◆ fft_gpu_finalize()

void fft_gpu_finalize ( void )

Releases resources held by the fft_gpu library.

Author
Ole Schuett

Definition at line 119 of file fft_gpu.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ensure_memory_sizes()

void ensure_memory_sizes ( const size_t requested_buffer_size,
const size_t requested_map_size )

Checks size of device buffers and re-allocates them if necessary.

Author
Ole Schuett
Parameters
requested_buffer_sizeRequested device buffer size in elements.
requested_map_sizeRequested index-map size in elements.
Author
Ole Schuett

Definition at line 156 of file fft_gpu.c.

Here is the caller graph for this function:

◆ fft_gpu_allocate_double()

void fft_gpu_allocate_double ( const int length,
double ** buffer )

Allocate buffer of type double.

Author
Frederick Stein
Parameters
lengthNumber of elements.
bufferBuffer pointer.
Author
Frederick Stein

Definition at line 185 of file fft_gpu.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ fft_gpu_allocate_complex()

void fft_gpu_allocate_complex ( const int length,
double complex ** buffer )

Allocate buffer of type double complex.

Author
Frederick Stein
Parameters
lengthNumber of elements.
bufferBuffer pointer.
Author
Frederick Stein

Definition at line 202 of file fft_gpu.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ fft_gpu_free_double()

void fft_gpu_free_double ( double * buffer)

Allocate buffer of type double.

Author
Frederick Stein
Parameters
bufferBuffer pointer.
Author
Frederick Stein

Definition at line 218 of file fft_gpu.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ fft_gpu_free_complex()

void fft_gpu_free_complex ( double complex * buffer)

Allocate buffer of type double complex.

Author
Frederick Stein
Parameters
bufferBuffer pointer.
Author
Frederick Stein

Definition at line 233 of file fft_gpu.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ fft_gpu_register_1d_local()

void fft_gpu_register_1d_local ( const bool dir,
const int n,
const int m,
const bool transpose_in,
const bool transpose_out,
const int leading_dimension_in,
const int leading_dimension_out,
const bool inplace )

Performs a (double precision complex) 1D-FFT on the GPU.

Author
Andreas Gloess, Ole Schuett
Parameters
dirFFT direction (forward or backward).
nTransform length.
mNumber of transforms.
transpose_inWhether the input array uses the transposed layout.
transpose_outWhether the output array uses the transposed layout.
leading_dimension_inLeading dimension of the input array.
leading_dimension_outLeading dimension of the output array.
inplaceWhether the transform is performed in-place.
Author
Andreas Gloess, Ole Schuett

Definition at line 933 of file fft_gpu.c.

Here is the caller graph for this function:

◆ fft_gpu_register_1d_r2c_local()

void fft_gpu_register_1d_r2c_local ( const bool dir,
const int n,
const int m,
const bool transpose_in,
const bool transpose_out,
const int leading_dimension_in,
const int leading_dimension_out,
const bool inplace )

Performs a (double precision complex) R2C 1D-FFT on the GPU.

Author
Andreas Gloess, Ole Schuett

Performs a (double precision complex) R2C 1D-FFT on the GPU.

Parameters
dirFFT direction (forward or backward).
nTransform length.
mNumber of transforms.
transpose_inWhether the input array uses the transposed layout.
transpose_outWhether the output array uses the transposed layout.
leading_dimension_inLeading dimension of the input array.
leading_dimension_outLeading dimension of the output array.
inplaceWhether the transform is performed in-place.
Author
Andreas Gloess, Ole Schuett

Definition at line 973 of file fft_gpu.c.

Here is the caller graph for this function:

◆ fft_gpu_register_2d_local()

void fft_gpu_register_2d_local ( const bool dir,
const int n[2],
const int m,
const bool transpose_in,
const bool transpose_out,
const bool inplace )

Performs a (double precision complex) 1D-FFT on the GPU.

Author
Frederick Stein

Performs a (double precision complex) 1D-FFT on the GPU.

Parameters
dirFFT direction (forward or backward).
nTransform length.
mNumber of transforms.
transpose_inWhether the input array uses the transposed layout.
transpose_outWhether the output array uses the transposed layout.
inplaceWhether the transform is performed in-place.
Author
Frederick Stein

Definition at line 1012 of file fft_gpu.c.

Here is the caller graph for this function:

◆ fft_gpu_register_2d_r2c_local()

void fft_gpu_register_2d_r2c_local ( const bool dir,
const int n[2],
const int m,
const bool transpose_in,
const bool transpose_out,
const bool inplace )

Performs a (double precision complex) R2C 1D-FFT on the GPU.

Author
Frederick Stein

Performs a (double precision complex) R2C 1D-FFT on the GPU.

Parameters
dirFFT direction (forward or backward).
nTransform length.
mNumber of transforms.
transpose_inWhether the input array uses the transposed layout.
transpose_outWhether the output array uses the transposed layout.
inplaceWhether the transform is performed in-place.
Author
Andreas Gloess, Ole Schuett

Definition at line 1045 of file fft_gpu.c.

Here is the caller graph for this function:

◆ fft_gpu_register_3d_local()

void fft_gpu_register_3d_local ( const bool dir,
const int * npts,
const bool inplace,
const int number_of_ffts,
const bool transpose_in,
const bool transpose_out )

Performs a (double precision complex) 3D-FFT on the GPU.

Author
Andreas Gloess, Ole Schuett
Parameters
dirFFT direction (forward or backward).
nptsTransform grid dimensions.
inplaceWhether the transform is performed in-place.
number_of_fftsNumber of independent (batched) transforms.
transpose_inWhether the input array uses the transposed layout.
transpose_outWhether the output array uses the transposed layout.
Author
Andreas Gloess, Ole Schuett

Definition at line 864 of file fft_gpu.c.

Here is the caller graph for this function:

◆ fft_gpu_register_3d_r2c_local()

void fft_gpu_register_3d_r2c_local ( const bool dir,
const int * npts,
const bool inplace,
const int number_of_ffts,
const bool transpose_in,
const bool transpose_out )

Performs a 3D-R2C/C2R-FFT, on the GPU.

Author
Andreas Gloess, Ole Schuett
Parameters
dirFFT direction (forward or backward).
nptsTransform grid dimensions.
inplaceWhether the transform is performed in-place.
number_of_fftsNumber of independent (batched) transforms.
transpose_inWhether the input array uses the transposed layout.
transpose_outWhether the output array uses the transposed layout.
Author
Andreas Gloess, Ole Schuett

Definition at line 897 of file fft_gpu.c.

Here is the caller graph for this function:

◆ fft_gpu_1d_local()

void fft_gpu_1d_local ( const double * zin,
double * zout,
const bool dir,
const int n,
const int m,
const bool transpose_in,
const bool transpose_out,
const int leading_dimension_in,
const int leading_dimension_out )

Performs a (double precision complex) 1D-FFT on the GPU.

Author
Andreas Gloess, Ole Schuett
Parameters
zinInput complex data.
zoutOutput complex data.
dirFFT direction (forward or backward).
nTransform length.
mNumber of transforms.
transpose_inWhether the input array uses the transposed layout.
transpose_outWhether the output array uses the transposed layout.
leading_dimension_inLeading dimension of the input array.
leading_dimension_outLeading dimension of the output array.
Author
Andreas Gloess, Ole Schuett

Definition at line 1457 of file fft_gpu.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ fft_gpu_1d_r2c_local()

void fft_gpu_1d_r2c_local ( const double * zin,
double * zout,
const bool dir,
const int n,
const int m,
const bool transpose_in,
const bool transpose_out,
const int leading_dimension_in,
const int leading_dimension_out )

Performs a (double precision complex) R2C 1D-FFT on the GPU.

Author
Andreas Gloess, Ole Schuett

Performs a (double precision complex) R2C 1D-FFT on the GPU.

Parameters
zinInput complex data.
zoutOutput complex data.
dirFFT direction (forward or backward).
nTransform length.
mNumber of transforms.
transpose_inWhether the input array uses the transposed layout.
transpose_outWhether the output array uses the transposed layout.
leading_dimension_inLeading dimension of the input array.
leading_dimension_outLeading dimension of the output array.
Author
Andreas Gloess, Ole Schuett

Definition at line 1522 of file fft_gpu.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ fft_gpu_2d_local()

void fft_gpu_2d_local ( const double * zin,
double * zout,
const bool dir,
const int n[2],
const int m,
const bool transpose_in,
const bool transpose_out )

Performs a (double precision complex) 1D-FFT on the GPU.

Author
Frederick Stein

Performs a (double precision complex) 1D-FFT on the GPU.

Parameters
zinInput complex data.
zoutOutput complex data.
dirFFT direction (forward or backward).
nTransform length.
mNumber of transforms.
transpose_inWhether the input array uses the transposed layout.
transpose_outWhether the output array uses the transposed layout.
Author
Frederick Stein

Definition at line 1582 of file fft_gpu.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ fft_gpu_2d_r2c_local()

void fft_gpu_2d_r2c_local ( const double * zin,
double * zout,
const bool dir,
const int n[2],
const int m,
const bool transpose_in,
const bool transpose_out )

Performs a (double precision complex) R2C 1D-FFT on the GPU.

Author
Frederick Stein

Performs a (double precision complex) R2C 1D-FFT on the GPU.

Parameters
zinInput complex data.
zoutOutput complex data.
dirFFT direction (forward or backward).
nTransform length.
mNumber of transforms.
transpose_inWhether the input array uses the transposed layout.
transpose_outWhether the output array uses the transposed layout.
Author
Andreas Gloess, Ole Schuett

Definition at line 1630 of file fft_gpu.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ fft_gpu_3d_local()

void fft_gpu_3d_local ( const double * zin,
double * zout,
const bool dir,
const int * npts,
const int number_of_ffts,
const bool transpose_in,
const bool transpose_out )

Performs a (double precision complex) 3D-FFT on the GPU.

Author
Andreas Gloess, Ole Schuett
Parameters
zinInput complex data.
zoutOutput complex data.
dirFFT direction (forward or backward).
nptsTransform grid dimensions.
number_of_fftsNumber of independent (batched) transforms.
transpose_inWhether the input array uses the transposed layout.
transpose_outWhether the output array uses the transposed layout.
Author
Andreas Gloess, Ole Schuett

Definition at line 1190 of file fft_gpu.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ fft_gpu_3d_r2c_local()

void fft_gpu_3d_r2c_local ( const double * zin,
double * zout,
const bool dir,
const int * npts,
const int number_of_ffts,
const bool transpose_in,
const bool transpose_out )

Performs a 3D-R2C/C2R-FFT, on the GPU.

Author
Andreas Gloess, Ole Schuett
Parameters
zinInput complex data.
zoutOutput complex data.
dirFFT direction (forward or backward).
nptsTransform grid dimensions.
number_of_fftsNumber of independent (batched) transforms.
transpose_inWhether the input array uses the transposed layout.
transpose_outWhether the output array uses the transposed layout.
Author
Andreas Gloess, Ole Schuett

Definition at line 1239 of file fft_gpu.c.

Here is the call graph for this function:
Here is the caller graph for this function: