Skip to content

FFT transforms

Module: Transform Functions

More...

Modules

Name
FFT kernels on complex input values
FFT kernels on real input values

Functions

Name
void plp_bitreversal_16s_rv32im(uint16_t * pSrc, const uint16_t bitRevLen, const uint16_t * pBitRevTab)
In-place 16 bit reversal function.
void plp_bitreversal_32s_rv32im(uint32_t * pSrc, const uint16_t bitRevLen, const uint16_t * pBitRevTab)
In-place 32 bit reversal function.
void plp_bitreversal_16s_xpulpv2(uint16_t * pSrc, const uint16_t bitRevLen, const uint16_t * pBitRevTab)
In-place 16 bit reversal function.
void plp_bitreversal_16p_xpulpv2(uint16_t * pSrc, const uint16_t bitRevLen, const uint16_t * pBitRevTab, uint32_t nPE)
In-place 16 bit reversal function.
void plp_bitreversal_32s_xpulpv2(uint32_t * pSrc, const uint16_t bitRevLen, const uint16_t * pBitRevTab)
In-place 32 bit reversal function for XPULPV2.
void plp_bitreversal_32p_xpulpv2(uint32_t * pSrc, const uint16_t bitRevLen, const uint16_t * pBitRevTab, uint32_t nPE)
In-place 32 bit reversal function for XPULPV2.
void plp_cfft_radix4by2_q16(int16_t * pSrc, uint32_t fftLen, const int16_t * pCoef, uint32_t nPE)
void plp_radix4_butterfly_q16(int16_t * pSrc16, uint32_t fftLen, int16_t * pCoef16, uint32_t twidCoefModifier, uint32_t nPE)
Core function for the Q15 CFFT butterfly process.
void plp_cfft_q16p_xpulpv2(void * args)
Parallel quantized 16 bit complex fast fourier transform for XPULPV2.
void plp_cfft_radix4by2_q16(int16_t * pSrc, uint32_t fftLen, const int16_t * pCoef)
void plp_radix4_butterfly_q16(int16_t * pSrc16, uint32_t fftLen, int16_t * pCoef16, uint32_t twidCoefModifier)
Core function for the Q15 CFFT butterfly process.
void plp_cfft_q16s_rv32im(const plp_cfft_instance_q16 * S, int16_t * p1, uint8_t ifftFlag, uint8_t bitReverseFlag, uint32_t deciPoint)
Quantized 16 bit complex fast fourier transform for RV32IM.
void plp_cfft_q16s_xpulpv2(const plp_cfft_instance_q16 * S, int16_t * p1, uint8_t ifftFlag, uint8_t bitReverseFlag, uint32_t deciPoint)
Quantized 16 bit complex fast fourier transform for XPULPV2.
void plp_cfft_radix4by2_q32(int32_t * pSrc, uint32_t fftLen, const int32_t * pCoef, uint32_t nPE)
void plp_radix4_butterfly_q32(int32_t * pSrc, uint32_t fftLen, int32_t * pCoef, uint32_t twidCoefModifier, uint32_t nPE)
void plp_cfft_q32p_xpulpv2(void * args)
Parallel quantized 32 bit complex fast fourier transform for XPULPV2.
void plp_cfft_radix4by2_q32(int32_t * pSrc, uint32_t fftLen, const int32_t * pCoef)
void plp_radix4_butterfly_q32(int32_t * pSrc, uint32_t fftLen, int32_t * pCoef, uint32_t twidCoefModifier)
void plp_cfft_q32s_rv32im(const plp_cfft_instance_q32 * S, int32_t * p1, uint8_t ifftFlag, uint8_t bitReverseFlag, uint32_t fracBits)
Quantized 32-bit complex fast fourier transform for RV32IM.
void plp_cfft_q32s_xpulpv2(const plp_cfft_instance_q32 * S, int32_t * p1, uint8_t ifftFlag, uint8_t bitReverseFlag, uint32_t fracBits)
Quantized 32-bit complex fast fourier transform for XPULPV2.
void plp_cfft_f32(const plp_cfft_instance_f32 * S, float32_t * pSrc, uint8_t ifftFlag, uint8_t bitReverseFlag)
Floating-point FFT on complex input data.
void plp_cfft_f32_parallel(const plp_cfft_instance_f32 * S, const float32_t * pSrc, uint8_t ifftFlag, uint8_t bitReverseFlag, const uint32_t nPE)
Floating-point FFT on complex input data (parallel version).
void plp_cfft_q16(const plp_cfft_instance_q16 * S, int16_t * p1, uint8_t ifftFlag, uint8_t bitReverseFlag, uint32_t deciPoint)
Glue code for quantized 16 bit complex fast fourier transform.
void plp_cfft_q16_parallel(const plp_cfft_instance_q16 * S, int16_t * p1, uint8_t ifftFlag, uint8_t bitReverseFlag, uint32_t deciPoint, uint32_t nPE)
Glue code for quantized 16 bit complex fast fourier transform.
void plp_cfft_q32(const plp_cfft_instance_q32 * S, int32_t * p1, uint8_t ifftFlag, uint8_t bitReverseFlag, uint32_t fracBits)
Glue code for quantized 32-bit complex fast fourier transform.
void plp_cfft_q32_parallel(const plp_cfft_instance_q32 * S, int32_t * p1, uint8_t ifftFlag, uint8_t bitReverseFlag, uint32_t fracBits, uint32_t nPE)
Quantized 32-bit complex fast fourier transform for XPULPV2.
void plp_dct2_f32(const plp_fft_instance_f32 * S, const Complex_type_f32 * pShift, const uint8_t orthoNorm, const float32_t restrict pSrc, float32_t restrict pBuf, float32_t *restrict pDst)
Floating-point DCT on real input data. Implementation of John Makhoul's "A Fast Cosine Transform in One and Two Dimensions" 1980 IEEE paper.
void plp_dct2_f32_parallel(const plp_fft_instance_f32 * S, const Complex_type_f32 * pShift, const uint8_t orthoNorm, const float32_t restrict pSrc, const uint32_t nPE, float32_t restrict pBuf, float32_t *restrict pDst)
Floating-point DCT on real input data. Parallelised implementation of John Makhoul's "A Fast Cosine Transform in One and Two Dimensions" 1980 IEEE paper.
void plp_rfft_f32(const plp_fft_instance_f32 * S, const float32_t restrict pSrc, float32_t restrict pDst)
Floating-point FFT on real input data.
void plp_rfft_f32_parallel(const plp_fft_instance_f32 * S, const float32_t restrict pSrc, const uint32_t nPE, float32_t restrict pDst)
Floating-point FFT on real input data (parallel version).
void plp_rfftfast_f32(const plp_fft_fast_instance_f32 * S, const float32_t restrict pSrc, float32_t restrict pDst)
Floating-point FFT on real input data.
void plp_rfftfast_f32_parallel(const plp_fft_fast_instance_f32 * S, float32_t restrict pSrc, float32_t restrict pDst, const uint32_t nPE)
Floating-point FFT on real input data.

Defines

Name
multAcc_32x32_keep32_R(a, x, y)
multSub_32x32_keep32_R(a, x, y)
mult_32x32_keep32_R(a, x, y)
multAcc_32x32_keep32_R(a, x, y)
multSub_32x32_keep32_R(a, x, y)
mult_32x32_keep32_R(a, x, y)
multAcc_32x32_keep32_R(a, x, y)
multSub_32x32_keep32_R(a, x, y)
mult_32x32_keep32_R(a, x, y)

Detailed Description

This module contains the code to perform FFT transforms.

Functions Documentation

function plp_bitreversal_16s_rv32im

void plp_bitreversal_16s_rv32im(
    uint16_t * pSrc,
    const uint16_t bitRevLen,
    const uint16_t * pBitRevTab
)

In-place 16 bit reversal function.

Parameters:

  • pSrc points to in-place buffer of unknown 16-bit data type
  • bitRevLen bit reversal table length
  • pBitRevTab points to bit reversal table

Return: none

In-place 16 bit reversal function for RV32IM.

function plp_bitreversal_32s_rv32im

void plp_bitreversal_32s_rv32im(
    uint32_t * pSrc,
    const uint16_t bitRevLen,
    const uint16_t * pBitRevTab
)

In-place 32 bit reversal function.

Parameters:

  • pSrc points to in-place buffer of unknown 32-bit data type
  • bitRevLen bit reversal table length
  • pBitRevTab points to bit reversal table

Return: none

In-place 32 bit reversal function for RV32IM.

function plp_bitreversal_16s_xpulpv2

void plp_bitreversal_16s_xpulpv2(
    uint16_t * pSrc,
    const uint16_t bitRevLen,
    const uint16_t * pBitRevTab
)

In-place 16 bit reversal function.

Parameters:

  • pSrc points to in-place buffer of unknown 16-bit data type
  • bitRevLen bit reversal table length
  • pBitRevTab points to bit reversal table

Return: none

In-place 16 bit reversal function for XPULPV2.

function plp_bitreversal_16p_xpulpv2

void plp_bitreversal_16p_xpulpv2(
    uint16_t * pSrc,
    const uint16_t bitRevLen,
    const uint16_t * pBitRevTab,
    uint32_t nPE
)

In-place 16 bit reversal function.

Parameters:

  • pSrc points to in-place buffer of unknown 16-bit data type
  • bitRevLen bit reversal table length
  • pBitRevTab points to bit reversal table
  • nPE number of cores

Return: none

function plp_bitreversal_32s_xpulpv2

void plp_bitreversal_32s_xpulpv2(
    uint32_t * pSrc,
    const uint16_t bitRevLen,
    const uint16_t * pBitRevTab
)

In-place 32 bit reversal function for XPULPV2.

Parameters:

  • pSrc points to in-place buffer of unknown 32-bit data type
  • bitRevLen bit reversal table length
  • pBitRevTab points to bit reversal table

Return: none

function plp_bitreversal_32p_xpulpv2

void plp_bitreversal_32p_xpulpv2(
    uint32_t * pSrc,
    const uint16_t bitRevLen,
    const uint16_t * pBitRevTab,
    uint32_t nPE
)

In-place 32 bit reversal function for XPULPV2.

Parameters:

  • pSrc points to in-place buffer of unknown 32-bit data type
  • bitRevLen bit reversal table length
  • pBitRevTab points to bit reversal table
  • nPE number of cores

Return: none

function plp_cfft_radix4by2_q16

static void plp_cfft_radix4by2_q16(
    int16_t * pSrc,
    uint32_t fftLen,
    const int16_t * pCoef,
    uint32_t nPE
)

function plp_radix4_butterfly_q16

static void plp_radix4_butterfly_q16(
    int16_t * pSrc16,
    uint32_t fftLen,
    int16_t * pCoef16,
    uint32_t twidCoefModifier,
    uint32_t nPE
)

Core function for the Q15 CFFT butterfly process.

Parameters:

  • *pSrc16 points to the in-place buffer of Q15 data type.
  • fftLen length of the FFT.
  • *pCoef16 points to twiddle coefficient buffer.
  • twidCoefModifier twiddle coefficient modifier that supports different size FFTs with the same twiddle factor table.

Return: none.

function plp_cfft_q16p_xpulpv2

void plp_cfft_q16p_xpulpv2(
    void * args
)

Parallel quantized 16 bit complex fast fourier transform for XPULPV2.

Parameters:

function plp_cfft_radix4by2_q16

static void plp_cfft_radix4by2_q16(
    int16_t * pSrc,
    uint32_t fftLen,
    const int16_t * pCoef
)

function plp_radix4_butterfly_q16

static void plp_radix4_butterfly_q16(
    int16_t * pSrc16,
    uint32_t fftLen,
    int16_t * pCoef16,
    uint32_t twidCoefModifier
)

Core function for the Q15 CFFT butterfly process.

Parameters:

  • *pSrc16 points to the in-place buffer of Q15 data type.
  • fftLen length of the FFT.
  • *pCoef16 points to twiddle coefficient buffer.
  • twidCoefModifier twiddle coefficient modifier that supports different size FFTs with the same twiddle factor table.

Return: none.

function plp_cfft_q16s_rv32im

void plp_cfft_q16s_rv32im(
    const plp_cfft_instance_q16 * S,
    int16_t * p1,
    uint8_t ifftFlag,
    uint8_t bitReverseFlag,
    uint32_t deciPoint
)

Quantized 16 bit complex fast fourier transform for RV32IM.

Parameters:

  • S points to an instance of the 16bit quantized CFFT structure
  • p1 points to the complex data buffer of size 2*fftLen. Processing occurs in-place.
  • ifftFlag flag that selects forward (ifftFlag=0) or inverse (ifftFlag=1) transform.
  • bitReverseFlag flag that enables (bitReverseFlag=1) of disables (bitReverseFlag=0) bit reversal of output.
  • deciPoint decimal point for right shift

function plp_cfft_q16s_xpulpv2

void plp_cfft_q16s_xpulpv2(
    const plp_cfft_instance_q16 * S,
    int16_t * p1,
    uint8_t ifftFlag,
    uint8_t bitReverseFlag,
    uint32_t deciPoint
)

Quantized 16 bit complex fast fourier transform for XPULPV2.

Parameters:

  • S points to an instance of the 16bit quantized CFFT structure
  • p1 points to the complex data buffer of size 2*fftLen. Processing occurs in-place.
  • ifftFlag flag that selects forward (ifftFlag=0) or inverse (ifftFlag=1) transform.
  • bitReverseFlag flag that enables (bitReverseFlag=1) of disables (bitReverseFlag=0) bit reversal of output.
  • deciPoint decimal point for right shift

function plp_cfft_radix4by2_q32

void plp_cfft_radix4by2_q32(
    int32_t * pSrc,
    uint32_t fftLen,
    const int32_t * pCoef,
    uint32_t nPE
)

function plp_radix4_butterfly_q32

static void plp_radix4_butterfly_q32(
    int32_t * pSrc,
    uint32_t fftLen,
    int32_t * pCoef,
    uint32_t twidCoefModifier,
    uint32_t nPE
)

function plp_cfft_q32p_xpulpv2

void plp_cfft_q32p_xpulpv2(
    void * args
)

Parallel quantized 32 bit complex fast fourier transform for XPULPV2.

Parameters:

function plp_cfft_radix4by2_q32

static void plp_cfft_radix4by2_q32(
    int32_t * pSrc,
    uint32_t fftLen,
    const int32_t * pCoef
)

function plp_radix4_butterfly_q32

static void plp_radix4_butterfly_q32(
    int32_t * pSrc,
    uint32_t fftLen,
    int32_t * pCoef,
    uint32_t twidCoefModifier
)

function plp_cfft_q32s_rv32im

void plp_cfft_q32s_rv32im(
    const plp_cfft_instance_q32 * S,
    int32_t * p1,
    uint8_t ifftFlag,
    uint8_t bitReverseFlag,
    uint32_t fracBits
)

Quantized 32-bit complex fast fourier transform for RV32IM.

Parameters:

  • S points to an instance of the 32bit quantized CFFT structure
  • p1 points to the complex data buffer of size 2*fftLen. Processing occurs in-place.
  • ifftFlag flag that selects forwart (ifftFlag=0) or inverse (ifftFlag=1)
  • bitReverseFlag flag that enables (bitReverseFlag=1) of disables (bitReverseFlag=0) bit reversal of output.
  • fracBits decimal point for right shift (input format Q(32-fracBits).fracBits)

function plp_cfft_q32s_xpulpv2

void plp_cfft_q32s_xpulpv2(
    const plp_cfft_instance_q32 * S,
    int32_t * p1,
    uint8_t ifftFlag,
    uint8_t bitReverseFlag,
    uint32_t fracBits
)

Quantized 32-bit complex fast fourier transform for XPULPV2.

Parameters:

  • S points to an instance of the 32bit quantized CFFT structure
  • p1 points to the complex data buffer of size 2*fftLen. Processing occurs in-place.
  • ifftFlag flag that selects forwart (ifftFlag=0) or inverse (ifftFlag=1)
  • bitReverseFlag flag that enables (bitReverseFlag=1) of disables (bitReverseFlag=0) bit reversal of output.
  • fracBits decimal point for right shift (input format Q(32-fracBits).fracBits)

function plp_cfft_f32

void plp_cfft_f32(
    const plp_cfft_instance_f32 * S,
    float32_t * pSrc,
    uint8_t ifftFlag,
    uint8_t bitReverseFlag
)

Floating-point FFT on complex input data.

Parameters:

  • S points to an instance of the floating-point FFT structure
  • pSrc points to the complex data buffer of size 2*fftLen. Processing occurs in-place.
  • ifftFlag flag that selects forwart (ifftFlag=0) or inverse (ifftFlag=1)
  • bitReverseFlag flag that enables (bitReverseFlag=1) of disables (bitReverseFlag=0) bit reversal of output.

Return: none

function plp_cfft_f32_parallel

void plp_cfft_f32_parallel(
    const plp_cfft_instance_f32 * S,
    const float32_t * pSrc,
    uint8_t ifftFlag,
    uint8_t bitReverseFlag,
    const uint32_t nPE
)

Floating-point FFT on complex input data (parallel version).

Parameters:

  • S points to an instance of the floating-point FFT structure
  • pSrc points to the complex data buffer of size 2*fftLen. Processing occurs in-place.
  • ifftFlag flag that selects forwart (ifftFlag=0) or inverse (ifftFlag=1)
  • bitReverseFlag flag that enables (bitReverseFlag=1) of disables (bitReverseFlag=0) bit reversal of output.
  • nPE number of parallel processing units

Return: none

function plp_cfft_q16

void plp_cfft_q16(
    const plp_cfft_instance_q16 * S,
    int16_t * p1,
    uint8_t ifftFlag,
    uint8_t bitReverseFlag,
    uint32_t deciPoint
)

Glue code for quantized 16 bit complex fast fourier transform.

Parameters:

  • S points to an instance of the 16bit quantized CFFT structure
  • p1 points to the complex data buffer of size 2*fftLen. Processing occurs in-place.
  • ifftFlag flag that selects forward (ifftFlag=0) or inverse (ifftFlag=1) transform.
  • bitReverseFlag flag that enables (bitReverseFlag=1) of disables (bitReverseFlag=0) bit reversal of output.
  • deciPoint decimal point for right shift

function plp_cfft_q16_parallel

void plp_cfft_q16_parallel(
    const plp_cfft_instance_q16 * S,
    int16_t * p1,
    uint8_t ifftFlag,
    uint8_t bitReverseFlag,
    uint32_t deciPoint,
    uint32_t nPE
)

Glue code for quantized 16 bit complex fast fourier transform.

Parameters:

  • S points to an instance of the 16bit quantized CFFT structure
  • p1 points to the complex data buffer of size 2*fftLen. Processing occurs in-place.
  • ifftFlag flag that selects forward (ifftFlag=0) or inverse (ifftFlag=1) transform.
  • bitReverseFlag flag that enables (bitReverseFlag=1) of disables (bitReverseFlag=0) bit reversal of output.
  • deciPoint decimal point for right shift
  • nPE Number of cores to use

Fixed point units input -> output dependent on length: len=16: Q1.15 -> Q5.11 len=32: Q1.15 -> Q6.10 len=64: Q1.15 -> Q7.9 len=128: Q1.15 -> Q8.8 len=256: Q1.15 -> Q9.7 len=512: Q1.15 -> Q10.6 len=1024: Q1.15 -> Q11.5 len=2048: Q1.15 -> Q12.4 len=4096: Q1.15 -> Q13.3

function plp_cfft_q32

void plp_cfft_q32(
    const plp_cfft_instance_q32 * S,
    int32_t * p1,
    uint8_t ifftFlag,
    uint8_t bitReverseFlag,
    uint32_t fracBits
)

Glue code for quantized 32-bit complex fast fourier transform.

Parameters:

  • S points to an instance of the 32bit quantized CFFT structure
  • p1 points to the complex data buffer of size 2*fftLen. Processing occurs in-place.
  • ifftFlag flag that selects forwart (ifftFlag=0) or inverse (ifftFlag=1)
  • bitReverseFlag flag that enables (bitReverseFlag=1) of disables (bitReverseFlag=0) bit reversal of output.
  • fracBits decimal point for right shift (input format Q(32-fracBits).fracBits)

function plp_cfft_q32_parallel

void plp_cfft_q32_parallel(
    const plp_cfft_instance_q32 * S,
    int32_t * p1,
    uint8_t ifftFlag,
    uint8_t bitReverseFlag,
    uint32_t fracBits,
    uint32_t nPE
)

Quantized 32-bit complex fast fourier transform for XPULPV2.

Parameters:

  • S points to an instance of the 32bit quantized CFFT structure
  • p1 points to the complex data buffer of size 2*fftLen. Processing occurs in-place.
  • ifftFlag flag that selects forwart (ifftFlag=0) or inverse (ifftFlag=1)
  • bitReverseFlag flag that enables (bitReverseFlag=1) of disables (bitReverseFlag=0) bit reversal of output.
  • fracBits decimal point for right shift (input format Q(32-fracBits).fracBits)
  • nPE Number of cores to use

function plp_dct2_f32

void plp_dct2_f32(
    const plp_fft_instance_f32 * S,
    const Complex_type_f32 * pShift,
    const uint8_t orthoNorm,
    const float32_t *__restrict__ pSrc,
    float32_t *__restrict__ pBuf,
    float32_t *__restrict__ pDst
)

Floating-point DCT on real input data. Implementation of John Makhoul's "A Fast Cosine Transform in One and Two Dimensions" 1980 IEEE paper.

Parameters:

  • S points to an instance of the floating-point FFT structure with FFTLength = DCTLength
  • pShift points to twiddle coefficient table of 4*FFTLength, of which only the first quadrant of the complex unit circle is used. For example, if S contains twiddleCoef_rfft_32, pShift can be set to twiddleCoef_rfft_128.
  • pSrc points to the input buffer (real data) of size FFTLength.
  • pBuf points to buffer of size 2*FFTLength, used for computation.
  • pDst points to output buffer (real data) of size FFTLength, may be the same as pSrc.

Return: none

function plp_dct2_f32_parallel

void plp_dct2_f32_parallel(
    const plp_fft_instance_f32 * S,
    const Complex_type_f32 * pShift,
    const uint8_t orthoNorm,
    const float32_t *__restrict__ pSrc,
    const uint32_t nPE,
    float32_t *__restrict__ pBuf,
    float32_t *__restrict__ pDst
)

Floating-point DCT on real input data. Parallelised implementation of John Makhoul's "A Fast Cosine Transform in One and Two Dimensions" 1980 IEEE paper.

Parameters:

  • S points to an instance of the floating-point FFT structure with FFTLength = DCTLength
  • pShift points to twiddle coefficient table of 4*FFTLength, of which only the first quadrant of the complex unit circle is used. For example, if S contains twiddleCoef_rfft_32, pShift can be set to twiddleCoef_rfft_128.
  • pSrc points to the input buffer (real data) of size FFTLength.
  • pBuf points to buffer of size 2*FFTLength, used for computation.
  • pDst points to output buffer (real data) of size FFTLength, may be the same as pSrc.

Return: none

Floating-point DCT on real input data. Implementation of John Makhoul's "A Fast Cosine Transform in One and Two Dimensions" 1980 IEEE paper.

function plp_rfft_f32

void plp_rfft_f32(
    const plp_fft_instance_f32 * S,
    const float32_t *__restrict__ pSrc,
    float32_t *__restrict__ pDst
)

Floating-point FFT on real input data.

Parameters:

  • S points to an instance of the floating-point FFT structure
  • pSrc points to the input buffer (real data)
  • pDst points to the output buffer (complex data)

Return: none

function plp_rfft_f32_parallel

void plp_rfft_f32_parallel(
    const plp_fft_instance_f32 * S,
    const float32_t *__restrict__ pSrc,
    const uint32_t nPE,
    float32_t *__restrict__ pDst
)

Floating-point FFT on real input data (parallel version).

Parameters:

  • S points to an instance of the floating-point FFT structure
  • pSrc points to the input buffer (real data)
  • nPE number of parallel processing units
  • pDst points to the output buffer (complex data)

Return: none

function plp_rfftfast_f32

void plp_rfftfast_f32(
    const plp_fft_fast_instance_f32 * S,
    const float32_t *__restrict__ pSrc,
    float32_t *__restrict__ pDst
)

Floating-point FFT on real input data.

Parameters:

  • S points to an instance of the floating-point FFT structure
  • pSrc points to the input buffer (real data)
  • pDst points to the output buffer (complex data)

Return: none

function plp_rfftfast_f32_parallel

void plp_rfftfast_f32_parallel(
    const plp_fft_fast_instance_f32 * S,
    float32_t *__restrict__ pSrc,
    float32_t *__restrict__ pDst,
    const uint32_t nPE
)

Floating-point FFT on real input data.

Parameters:

  • S points to an instance of the floating-point FFT structure
  • pSrc points to the input buffer (real data)
  • pDst points to the output buffer (complex data)

Return: none

Floating-point parallel FFT on real input data.

Macros Documentation

define multAcc_32x32_keep32_R

#define multAcc_32x32_keep32_R(
    a,
    x,
    y
)
    a = (int32_t) (((((int64_t) a) << 32) + ((int64_t) x * y) + 0x80000000LL ) >> 32)

define multSub_32x32_keep32_R

#define multSub_32x32_keep32_R(
    a,
    x,
    y
)
    a = (int32_t) (((((int64_t) a) << 32) - ((int64_t) x * y) + 0x80000000LL ) >> 32)

define mult_32x32_keep32_R

#define mult_32x32_keep32_R(
    a,
    x,
    y
)
    a = (int32_t) (((int64_t) x * y + 0x80000000LL ) >> 32)

define multAcc_32x32_keep32_R

#define multAcc_32x32_keep32_R(
    a,
    x,
    y
)
    a = (int32_t) (((((int64_t) a) << 32) + ((int64_t) x * y) + 0x80000000LL ) >> 32)

define multSub_32x32_keep32_R

#define multSub_32x32_keep32_R(
    a,
    x,
    y
)
    a = (int32_t) (((((int64_t) a) << 32) - ((int64_t) x * y) + 0x80000000LL ) >> 32)

define mult_32x32_keep32_R

#define mult_32x32_keep32_R(
    a,
    x,
    y
)
    a = (int32_t) (((int64_t) x * y + 0x80000000LL ) >> 32)

define multAcc_32x32_keep32_R

#define multAcc_32x32_keep32_R(
    a,
    x,
    y
)
    a = (int32_t) (((((int64_t) a) << 32) + ((int64_t) x * y) + 0x80000000LL ) >> 32)

define multSub_32x32_keep32_R

#define multSub_32x32_keep32_R(
    a,
    x,
    y
)
    a = (int32_t) (((((int64_t) a) << 32) - ((int64_t) x * y) + 0x80000000LL ) >> 32)

define mult_32x32_keep32_R

#define mult_32x32_keep32_R(
    a,
    x,
    y
)
    a = (int32_t) (((int64_t) x * y + 0x80000000LL ) >> 32)

Updated on 2023-03-01 at 16:16:32 +0000