|
AI Engine API User Guide (AIE-API) 2024.2
|
Overview
Stage-based FFT APIs
The AIE API offers a stage-based interface for carrying out decimation-in-time FFTs. For example, assuming twiddle pointer visibility (see Twiddle Generation below), a 1024 point FFT can be computed as follows:
Similarly, a 512 point FFT can be implemented, using a mix of radix-2 and radix-4 stages, as follows:
- Note
- For an odd number of stages the input buffer may be used in place of the
tmp, which could be of benefit for large FFTs. - The order of the twiddle arguments are outlined in the description of each FFT stage function: aie::fft_dit_r2_stage, aie::fft_dit_r3_stage, aie::fft_dit_r4_stage, aie::fft_dit_r5_stage
Twiddle Generation
An R-Radix, N-point FFT requires R-1 twiddle tables per stage.
Each of the tables are of length (n_stage / R), where n_stage is the local number of samples of the current radix stage. The local number of samples is given as the total point size, N, divided by the Vectorization, which is the template parameter of the fft_dit_r*_stage function calls. This is due to the fact that earlier stages of an N-point FFT are smaller, batched FFTs.
For each stage, the twiddle tables can be computed, in floating point, as:
and the equivalent python code:
For fixed point implementations, the twiddle values should be multiplied by (1 << shift_tw) before converting to the output type. For example,
Full FFT Example
Using the method of generating twiddles outlined in Twiddle Generation, a 128pt FFT can be computed as follows:
- Note
- Note the order of the twiddles to the radix 4 stages are not in increasing order; i.e. defining the rotation rate of a given twiddle to be
w(tw), the relationship between the twiddle groups arew(tw1) < w(tw0) < w(tw2). This is not the case for other radix stages, where the rotation rate is monotonically increasing; i.e.w(tw1) < ... < w(twN).
Typedefs | |
| template<unsigned Vectorization, unsigned Radix, typename Input , typename Output = Input, typename Twiddle = detail::default_twiddle_type_t<Input, Output>> | |
| using | aie::fft_dit = detail::fft_dit< Vectorization, detail::fft_get_stage< Input, Output, Twiddle >(Radix, Vectorization), Radix, Input, Output, Twiddle > |
| Type that encapsulates the functionality for decimation-in-time FFTs. | |
Functions | |
| template<unsigned Vectorization, typename Input , typename Output , typename Twiddle > requires (arch::is(arch::AIE, arch::AIE_ML) && detail::is_floating_point_v<Input>) | |
| void | aie::fft_dit_r2_stage (const Input *__restrict x, const Twiddle *__restrict tw, unsigned n, bool inv, Output *__restrict out) |
| A function to perform a single floating point radix 2 FFT stage. | |
| template<unsigned Vectorization, typename Input , typename Output , typename Twiddle > requires (arch::is(arch::Gen1, arch::Gen2)) | |
| void | aie::fft_dit_r2_stage (const Input *__restrict x, const Twiddle *__restrict tw, unsigned n, unsigned shift_tw, unsigned shift, bool inv, Output *__restrict out) |
| A function to perform a single radix 2 FFT stage. | |
| template<typename Input , typename Output , typename Twiddle > requires (arch::is(arch::AIE) && detail::is_floating_point_v<Input>) | |
| void | aie::fft_dit_r2_stage (const Input *__restrict x, const Twiddle *__restrict tw, unsigned n, unsigned vectorization, bool inv, Output *__restrict out) |
| A function to perform a single floating point radix 2 FFT stage with dynamic vectorization. | |
| template<typename Input , typename Output , typename Twiddle > requires (arch::is(arch::AIE)) | |
| void | aie::fft_dit_r2_stage (const Input *__restrict x, const Twiddle *__restrict tw, unsigned n, unsigned vectorization, unsigned shift_tw, unsigned shift, bool inv, Output *__restrict out) |
| A function to perform a single radix 2 FFT stage with dynamic vectorization. | |
| template<unsigned Vectorization, typename Input , typename Output , typename Twiddle > requires (arch::is(arch::AIE) && detail::is_floating_point_v<Input>) | |
| void | aie::fft_dit_r3_stage (const Input *__restrict x, const Twiddle *__restrict tw0, const Twiddle *__restrict tw1, unsigned n, bool inv, Output *__restrict out) |
| A function to perform a single floating point radix 3 FFT stage. | |
| template<unsigned Vectorization, typename Input , typename Output , typename Twiddle > requires (arch::is(arch::AIE, arch::AIE_ML)) | |
| void | aie::fft_dit_r3_stage (const Input *__restrict x, const Twiddle *__restrict tw0, const Twiddle *__restrict tw1, unsigned n, unsigned shift_tw, unsigned shift, bool inv, Output *__restrict out) |
| A function to perform a single radix 3 FFT stage. | |
| template<typename Input , typename Output , typename Twiddle > requires (arch::is(arch::AIE) && detail::is_floating_point_v<Input>) | |
| void | aie::fft_dit_r3_stage (const Input *__restrict x, const Twiddle *__restrict tw0, const Twiddle *__restrict tw1, unsigned n, unsigned vectorization, bool inv, Output *__restrict out) |
| A function to perform a single floating point radix 3 FFT stage with dynamic vectorization. | |
| template<typename Input , typename Output , typename Twiddle > requires (arch::is(arch::AIE)) | |
| void | aie::fft_dit_r3_stage (const Input *__restrict x, const Twiddle *__restrict tw0, const Twiddle *__restrict tw1, unsigned n, unsigned vectorization, unsigned shift_tw, unsigned shift, bool inv, Output *__restrict out) |
| A function to perform a single radix 3 FFT stage with dynamic vectorization. | |
| template<unsigned Vectorization, typename Input , typename Output , typename Twiddle > requires (arch::is(arch::Gen1, arch::Gen2)) | |
| void | aie::fft_dit_r4_stage (const Input *__restrict x, const Twiddle *__restrict tw0, const Twiddle *__restrict tw1, const Twiddle *__restrict tw2, unsigned n, unsigned shift_tw, unsigned shift, bool inv, Output *__restrict out) |
| A function to perform a single radix 4 FFT stage. | |
| template<typename Input , typename Output , typename Twiddle > requires (arch::is(arch::AIE)) | |
| void | aie::fft_dit_r4_stage (const Input *__restrict x, const Twiddle *__restrict tw0, const Twiddle *__restrict tw1, const Twiddle *__restrict tw2, unsigned n, unsigned vectorization, unsigned shift_tw, unsigned shift, bool inv, Output *__restrict out) |
| A function to perform a single radix 4 FFT stage with dynamic vectorization. | |
| template<unsigned Vectorization, typename Input , typename Output , typename Twiddle > requires (arch::is(arch::AIE) && detail::is_floating_point_v<Input>) | |
| void | aie::fft_dit_r5_stage (const Input *__restrict x, const Twiddle *__restrict tw0, const Twiddle *__restrict tw1, const Twiddle *__restrict tw2, const Twiddle *__restrict tw3, unsigned n, bool inv, Output *__restrict out) |
| A function to perform a single floating point radix 5 FFT stage. | |
| template<unsigned Vectorization, typename Input , typename Output , typename Twiddle > requires (arch::is(arch::AIE, arch::AIE_ML)) | |
| void | aie::fft_dit_r5_stage (const Input *__restrict x, const Twiddle *__restrict tw0, const Twiddle *__restrict tw1, const Twiddle *__restrict tw2, const Twiddle *__restrict tw3, unsigned n, unsigned shift_tw, unsigned shift, bool inv, Output *out) |
| A function to perform a single radix 5 FFT stage. | |
| template<typename Input , typename Output , typename Twiddle > requires (arch::is(arch::AIE) && detail::is_floating_point_v<Input>) | |
| void | aie::fft_dit_r5_stage (const Input *__restrict x, const Twiddle *__restrict tw0, const Twiddle *__restrict tw1, const Twiddle *__restrict tw2, const Twiddle *__restrict tw3, unsigned n, unsigned vectorization, bool inv, Output *__restrict out) |
| A function to perform a single floating point radix 5 FFT stage with dynamic vectorization. | |
| template<typename Input , typename Output , typename Twiddle > requires (arch::is(arch::AIE)) | |
| void | aie::fft_dit_r5_stage (const Input *__restrict x, const Twiddle *__restrict tw0, const Twiddle *__restrict tw1, const Twiddle *__restrict tw2, const Twiddle *__restrict tw3, unsigned n, unsigned vectorization, unsigned shift_tw, unsigned shift, bool inv, Output *out) |
| A function to perform a single radix 5 FFT stage with dynamic vectorization. | |
Supported Fast Fourier Transform Modes
| Input Type | Output Type | Twiddle Type | AIE Supported Radices | AIE-ML/XDNA 1 Supported Radices |
|---|---|---|---|---|
| c16b | c16b | c16b | 2, 3, 4, 5 | 2, 3, 4, 5 |
| c16b | c32b | c16b | 2, 3, 4, 5 | 2, 3, 4, 5 |
| c32b | c16b | c16b | 2, 3, 4, 5 | 2, 3, 4, 5 |
| c32b | c32b | c16b | 2, 3, 4, 5 | 2, 3, 4, 5 |
| c16b | c32b | c32b | 2 | |
| c32b | c16b | c32b | 2 | |
| c32b | c32b | c32b | 2, 3, 4, 5 | |
| cbfloat16 | cbfloat16 | cbfloat16 | 2, 4 | |
| cfloat | cfloat | cfloat | 2, 3, 5 |
- Note
- Odd-radix FFT stages are only available for vectorization values greater than or equal to the underlying output vector sizes.
Underlying output vector sizes Input Type Output Type Twiddle Type AIE Output Vector Size AIE-ML/XDNA 1 Output Vector Size c16b c16b c16b 4 (8 for radix 2) 8 c16b c32b c16b 4 (8 for radix 2) 8 c32b c16b c16b 4 8 c32b c32b c16b 4 8 c16b c32b c32b 4 c32b c16b c32b 4 c32b c32b c32b 2 cbfloat16 cbfloat16 cbfloat16 8 cfloat cfloat cfloat 4 - The minimum point size supported by an FFT is given by the product of the radix with the underlying output vector size. This is due to the fact that a radix R FFT will use R output pointers, each writing an amount of data equal to the underlying output vector size. For example, a radix 4 FFT with cint16 input data, cint32 output data, and cint16 twiddles will have a minimum point size of 16 (4 * 4) on AIE while the minimum point size on AIE-ML/XDNA 1 will be 32 (4 * 8).
Typedef Documentation
◆ fft_dit
| using aie::fft_dit = typedef detail::fft_dit<Vectorization, detail::fft_get_stage<Input, Output, Twiddle>(Radix, Vectorization), Radix, Input, Output, Twiddle> |
Type that encapsulates the functionality for decimation-in-time FFTs.
- Deprecated:
- The iterator interface is deprecated and the stage-based interface should be preferred. For example, where a user would previously need to define an FFT stage as follows:
the user may now replace all calls to the user-defined function function with the equivalent defined by the API:
- Template Parameters
-
Vectorization Vectorization of the FFT stage Radix Number which selects the FFT radix. Input Type of the input elements. Output Type of the output elements, defaults to input type. Twiddle Type of the twiddle elements, defaults to cint16 for integral types and cfloat for floating point.
Function Documentation
◆ fft_dit_r2_stage() [1/4]
requires (arch::is(arch::AIE, arch::AIE_ML) && detail::is_floating_point_v<Input>)
| void aie::fft_dit_r2_stage | ( | const Input *__restrict | x, |
| const Twiddle *__restrict | tw, | ||
| unsigned | n, | ||
| bool | inv, | ||
| Output *__restrict | out | ||
| ) |
A function to perform a single floating point radix 2 FFT stage.
- Parameters
-
x Input data pointer tw Twiddle group pointer n Number of samples inv Run inverse FFT stage out Output data pointer
- Template Parameters
-
Vectorization Vectorization of the FFT stage Input Type of the input elements. Output Type of the output elements, defaults to input type. Twiddle Type of the twiddle elements, defaults to cint16 for integral types and cfloat for floating point.
◆ fft_dit_r2_stage() [2/4]
requires (arch::is(arch::Gen1, arch::Gen2))
| void aie::fft_dit_r2_stage | ( | const Input *__restrict | x, |
| const Twiddle *__restrict | tw, | ||
| unsigned | n, | ||
| unsigned | shift_tw, | ||
| unsigned | shift, | ||
| bool | inv, | ||
| Output *__restrict | out | ||
| ) |
A function to perform a single radix 2 FFT stage.
- Parameters
-
x Input data pointer tw Twiddle group pointer n Number of samples shift_tw Indicates the decimal point of the twiddles (unused for float types) shift Shift applied to apply to dit outputs (unused for float types) inv Run inverse FFT stage out Output data pointer
- Template Parameters
-
Vectorization Vectorization of the FFT stage Input Type of the input elements. Output Type of the output elements, defaults to input type. Twiddle Type of the twiddle elements, defaults to cint16 for integral types and cfloat for floating point.
◆ fft_dit_r2_stage() [3/4]
requires (arch::is(arch::AIE) && detail::is_floating_point_v<Input>)
| void aie::fft_dit_r2_stage | ( | const Input *__restrict | x, |
| const Twiddle *__restrict | tw, | ||
| unsigned | n, | ||
| unsigned | vectorization, | ||
| bool | inv, | ||
| Output *__restrict | out | ||
| ) |
A function to perform a single floating point radix 2 FFT stage with dynamic vectorization.
This will incur additional overhead compared to the static vectorization implementation.
- Parameters
-
x Input data pointer tw Twiddle group pointer n Number of samples vectorization Vectorization of the FFT stage inv Run inverse FFT stage out Output data pointer
- Template Parameters
-
Input Type of the input elements. Output Type of the output elements, defaults to input type. Twiddle Type of the twiddle elements, defaults to cint16 for integral types and cfloat for floating point.
◆ fft_dit_r2_stage() [4/4]
requires (arch::is(arch::AIE))
| void aie::fft_dit_r2_stage | ( | const Input *__restrict | x, |
| const Twiddle *__restrict | tw, | ||
| unsigned | n, | ||
| unsigned | vectorization, | ||
| unsigned | shift_tw, | ||
| unsigned | shift, | ||
| bool | inv, | ||
| Output *__restrict | out | ||
| ) |
A function to perform a single radix 2 FFT stage with dynamic vectorization.
This will incur additional overhead compared to the static vectorization implementation.
- Parameters
-
x Input data pointer tw Twiddle group pointer n Number of samples vectorization Vectorization of the FFT stage shift_tw Indicates the decimal point of the twiddles (unused for float types) shift Shift applied to apply to dit outputs (unused for float types) inv Run inverse FFT stage out Output data pointer
- Template Parameters
-
Input Type of the input elements. Output Type of the output elements, defaults to input type. Twiddle Type of the twiddle elements, defaults to cint16 for integral types and cfloat for floating point.
◆ fft_dit_r3_stage() [1/4]
requires (arch::is(arch::AIE) && detail::is_floating_point_v<Input>)
| void aie::fft_dit_r3_stage | ( | const Input *__restrict | x, |
| const Twiddle *__restrict | tw0, | ||
| const Twiddle *__restrict | tw1, | ||
| unsigned | n, | ||
| bool | inv, | ||
| Output *__restrict | out | ||
| ) |
A function to perform a single floating point radix 3 FFT stage.
Defining the rotation rate of a given twiddle to be w(tw), the relationship between the twiddle groups are
- Parameters
-
x Input data pointer tw0 First twiddle group pointer tw1 Second twiddle group pointer n Number of samples inv Run inverse FFT stage out Output data pointer
- Template Parameters
-
Vectorization Vectorization of the FFT stage Input Type of the input elements. Output Type of the output elements, defaults to input type. Twiddle Type of the twiddle elements, defaults to cint16 for integral types and cfloat for floating point.
◆ fft_dit_r3_stage() [2/4]
requires (arch::is(arch::AIE, arch::AIE_ML))
| void aie::fft_dit_r3_stage | ( | const Input *__restrict | x, |
| const Twiddle *__restrict | tw0, | ||
| const Twiddle *__restrict | tw1, | ||
| unsigned | n, | ||
| unsigned | shift_tw, | ||
| unsigned | shift, | ||
| bool | inv, | ||
| Output *__restrict | out | ||
| ) |
A function to perform a single radix 3 FFT stage.
Defining the rotation rate of a given twiddle to be w(tw), the relationship between the twiddle groups are
- Parameters
-
x Input data pointer tw0 First twiddle group pointer tw1 Second twiddle group pointer n Number of samples shift_tw Indicates the decimal point of the twiddles (unused for float types) shift Shift applied to apply to dit outputs (unused for float types) inv Run inverse FFT stage out Output data pointer
- Template Parameters
-
Vectorization Vectorization of the FFT stage Input Type of the input elements. Output Type of the output elements, defaults to input type. Twiddle Type of the twiddle elements, defaults to cint16 for integral types and cfloat for floating point.
◆ fft_dit_r3_stage() [3/4]
requires (arch::is(arch::AIE) && detail::is_floating_point_v<Input>)
| void aie::fft_dit_r3_stage | ( | const Input *__restrict | x, |
| const Twiddle *__restrict | tw0, | ||
| const Twiddle *__restrict | tw1, | ||
| unsigned | n, | ||
| unsigned | vectorization, | ||
| bool | inv, | ||
| Output *__restrict | out | ||
| ) |
A function to perform a single floating point radix 3 FFT stage with dynamic vectorization.
This will incur additional overhead compared to the static vectorization implementation.
Defining the rotation rate of a given twiddle to be w(tw), the relationship between the twiddle groups are
- Parameters
-
x Input data pointer tw0 First twiddle group pointer tw1 Second twiddle group pointer n Number of samples vectorization Vectorization of the FFT stage inv Run inverse FFT stage out Output data pointer
- Template Parameters
-
Input Type of the input elements. Output Type of the output elements, defaults to input type. Twiddle Type of the twiddle elements, defaults to cint16 for integral types and cfloat for floating point.
◆ fft_dit_r3_stage() [4/4]
requires (arch::is(arch::AIE))
| void aie::fft_dit_r3_stage | ( | const Input *__restrict | x, |
| const Twiddle *__restrict | tw0, | ||
| const Twiddle *__restrict | tw1, | ||
| unsigned | n, | ||
| unsigned | vectorization, | ||
| unsigned | shift_tw, | ||
| unsigned | shift, | ||
| bool | inv, | ||
| Output *__restrict | out | ||
| ) |
A function to perform a single radix 3 FFT stage with dynamic vectorization.
This will incur additional overhead compared to the static vectorization implementation.
Defining the rotation rate of a given twiddle to be w(tw), the relationship between the twiddle groups are
- Parameters
-
x Input data pointer tw0 First twiddle group pointer tw1 Second twiddle group pointer n Number of samples vectorization Vectorization of the FFT stage shift_tw Indicates the decimal point of the twiddles (unused for float types) shift Shift applied to apply to dit outputs (unused for float types) inv Run inverse FFT stage out Output data pointer
- Template Parameters
-
Input Type of the input elements. Output Type of the output elements, defaults to input type. Twiddle Type of the twiddle elements, defaults to cint16 for integral types and cfloat for floating point.
◆ fft_dit_r4_stage() [1/2]
requires (arch::is(arch::Gen1, arch::Gen2))
| void aie::fft_dit_r4_stage | ( | const Input *__restrict | x, |
| const Twiddle *__restrict | tw0, | ||
| const Twiddle *__restrict | tw1, | ||
| const Twiddle *__restrict | tw2, | ||
| unsigned | n, | ||
| unsigned | shift_tw, | ||
| unsigned | shift, | ||
| bool | inv, | ||
| Output *__restrict | out | ||
| ) |
A function to perform a single radix 4 FFT stage.
Defining the rotation rate of a given twiddle to be w(tw), the relationship between the twiddle groups are
- Parameters
-
x Input data pointer tw0 First twiddle group pointer tw1 Second twiddle group pointer tw2 Third twiddle group pointer n Number of samples shift_tw Indicates the decimal point of the twiddles (unused for float types) shift Shift applied to apply to dit outputs (unused for float types) inv Run inverse FFT stage out Output data pointer
- Template Parameters
-
Vectorization Vectorization of the FFT stage Input Type of the input elements. Output Type of the output elements, defaults to input type. Twiddle Type of the twiddle elements, defaults to cint16 for integral types and cfloat for floating point.
◆ fft_dit_r4_stage() [2/2]
requires (arch::is(arch::AIE))
| void aie::fft_dit_r4_stage | ( | const Input *__restrict | x, |
| const Twiddle *__restrict | tw0, | ||
| const Twiddle *__restrict | tw1, | ||
| const Twiddle *__restrict | tw2, | ||
| unsigned | n, | ||
| unsigned | vectorization, | ||
| unsigned | shift_tw, | ||
| unsigned | shift, | ||
| bool | inv, | ||
| Output *__restrict | out | ||
| ) |
A function to perform a single radix 4 FFT stage with dynamic vectorization.
This will incur additional overhead compared to the static vectorization implementation.
Defining the rotation rate of a given twiddle to be w(tw), the relationship between the twiddle groups are
- Parameters
-
x Input data pointer tw0 First twiddle group pointer tw1 Second twiddle group pointer tw2 Third twiddle group pointer n Number of samples vectorization Vectorization of the FFT stage shift_tw Indicates the decimal point of the twiddles (unused for float types) shift Shift applied to apply to dit outputs (unused for float types) inv Run inverse FFT stage out Output data pointer
- Template Parameters
-
Input Type of the input elements. Output Type of the output elements, defaults to input type. Twiddle Type of the twiddle elements, defaults to cint16 for integral types and cfloat for floating point.
◆ fft_dit_r5_stage() [1/4]
requires (arch::is(arch::AIE) && detail::is_floating_point_v<Input>)
| void aie::fft_dit_r5_stage | ( | const Input *__restrict | x, |
| const Twiddle *__restrict | tw0, | ||
| const Twiddle *__restrict | tw1, | ||
| const Twiddle *__restrict | tw2, | ||
| const Twiddle *__restrict | tw3, | ||
| unsigned | n, | ||
| bool | inv, | ||
| Output *__restrict | out | ||
| ) |
A function to perform a single floating point radix 5 FFT stage.
Defining the rotation rate of a given twiddle to be w(tw), the relationship between the twiddle groups are
- Parameters
-
x Input data pointer tw0 First twiddle group pointer tw1 Second twiddle group pointer tw2 Third twiddle group pointer tw3 Fourth twiddle group pointer n Number of samples inv Run inverse FFT stage out Output data pointer
- Template Parameters
-
Vectorization Vectorization of the FFT stage Input Type of the input elements. Output Type of the output elements, defaults to input type. Twiddle Type of the twiddle elements, defaults to cint16 for integral types and cfloat for floating point.
◆ fft_dit_r5_stage() [2/4]
requires (arch::is(arch::AIE, arch::AIE_ML))
| void aie::fft_dit_r5_stage | ( | const Input *__restrict | x, |
| const Twiddle *__restrict | tw0, | ||
| const Twiddle *__restrict | tw1, | ||
| const Twiddle *__restrict | tw2, | ||
| const Twiddle *__restrict | tw3, | ||
| unsigned | n, | ||
| unsigned | shift_tw, | ||
| unsigned | shift, | ||
| bool | inv, | ||
| Output * | out | ||
| ) |
A function to perform a single radix 5 FFT stage.
Defining the rotation rate of a given twiddle to be w(tw), the relationship between the twiddle groups are
- Parameters
-
x Input data pointer tw0 First twiddle group pointer tw1 Second twiddle group pointer tw2 Third twiddle group pointer tw3 Fourth twiddle group pointer n Number of samples shift_tw Indicates the decimal point of the twiddles (unused for float types) shift Shift applied to apply to dit outputs (unused for float types) inv Run inverse FFT stage out Output data pointer
- Template Parameters
-
Vectorization Vectorization of the FFT stage Input Type of the input elements. Output Type of the output elements, defaults to input type. Twiddle Type of the twiddle elements, defaults to cint16 for integral types and cfloat for floating point.
◆ fft_dit_r5_stage() [3/4]
requires (arch::is(arch::AIE) && detail::is_floating_point_v<Input>)
| void aie::fft_dit_r5_stage | ( | const Input *__restrict | x, |
| const Twiddle *__restrict | tw0, | ||
| const Twiddle *__restrict | tw1, | ||
| const Twiddle *__restrict | tw2, | ||
| const Twiddle *__restrict | tw3, | ||
| unsigned | n, | ||
| unsigned | vectorization, | ||
| bool | inv, | ||
| Output *__restrict | out | ||
| ) |
A function to perform a single floating point radix 5 FFT stage with dynamic vectorization.
This will incur additional overhead compared to the static vectorization implementation.
Defining the rotation rate of a given twiddle to be w(tw), the relationship between the twiddle groups are
- Parameters
-
x Input data pointer tw0 First twiddle group pointer tw1 Second twiddle group pointer tw2 Third twiddle group pointer tw3 Fourth twiddle group pointer n Number of samples vectorization Vectorization of the FFT stage inv Run inverse FFT stage out Output data pointer
- Template Parameters
-
Input Type of the input elements. Output Type of the output elements, defaults to input type. Twiddle Type of the twiddle elements, defaults to cint16 for integral types and cfloat for floating point.
◆ fft_dit_r5_stage() [4/4]
requires (arch::is(arch::AIE))
| void aie::fft_dit_r5_stage | ( | const Input *__restrict | x, |
| const Twiddle *__restrict | tw0, | ||
| const Twiddle *__restrict | tw1, | ||
| const Twiddle *__restrict | tw2, | ||
| const Twiddle *__restrict | tw3, | ||
| unsigned | n, | ||
| unsigned | vectorization, | ||
| unsigned | shift_tw, | ||
| unsigned | shift, | ||
| bool | inv, | ||
| Output * | out | ||
| ) |
A function to perform a single radix 5 FFT stage with dynamic vectorization.
This will incur additional overhead compared to the static vectorization implementation.
Defining the rotation rate of a given twiddle to be w(tw), the relationship between the twiddle groups are
- Parameters
-
x Input data pointer tw0 First twiddle group pointer tw1 Second twiddle group pointer tw2 Third twiddle group pointer tw3 Fourth twiddle group pointer n Number of samples vectorization Vectorization of the FFT stage shift_tw Indicates the decimal point of the twiddles (unused for float types) shift Shift applied to apply to dit outputs (unused for float types) inv Run inverse FFT stage out Output data pointer
- Template Parameters
-
Input Type of the input elements. Output Type of the output elements, defaults to input type. Twiddle Type of the twiddle elements, defaults to cint16 for integral types and cfloat for floating point.