Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

change 'const static' to 'static const' to fix gcc compiler warning '… #260

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions modules/dsp/NE10_fft.neonintrinsic.h
Original file line number Diff line number Diff line change
Expand Up @@ -113,14 +113,14 @@
#define CONST_TW_81 0.70710678
#define CONST_TW_81N -0.70710678

const static float32x4_t Q_TW_81 = VDUPQ_N_F32(CONST_TW_81 );
const static float32x4_t Q_TW_81N = VDUPQ_N_F32(CONST_TW_81N);
static const float32x4_t Q_TW_81 = VDUPQ_N_F32(CONST_TW_81 );
static const float32x4_t Q_TW_81N = VDUPQ_N_F32(CONST_TW_81N);

#define DIV_TW81 1.4142136f
#define DIV_TW81N -1.4142136f

const static float32x4_t DIV_TW81_NEON = VDUPQ_N_F32(DIV_TW81);
const static float32x4_t DIV_TW81N_NEON = VDUPQ_N_F32(DIV_TW81N);
static const float32x4_t DIV_TW81_NEON = VDUPQ_N_F32(DIV_TW81);
static const float32x4_t DIV_TW81N_NEON = VDUPQ_N_F32(DIV_TW81N);

#define NE10_RADIX8x4_R2C_NEON_KERNEL_S1(Q_OUT,Q_IN) do { \
Q_OUT ## 0 = vaddq_f32 (Q_IN ## 0, Q_IN ## 4); \
Expand Down
20 changes: 10 additions & 10 deletions modules/dsp/NE10_fft_common_varibles.h
Original file line number Diff line number Diff line change
Expand Up @@ -40,36 +40,36 @@
///////////////////////////

/* Twiddles used in Radix-8 FFT */
const static ne10_float32_t TW_81_F32 = 0.70710678; // sqrt (2) / 2
const static ne10_float32_t TW_81N_F32 = -0.70710678; // - TW_81_F32
static const ne10_float32_t TW_81_F32 = 0.70710678; // sqrt (2) / 2
static const ne10_float32_t TW_81N_F32 = -0.70710678; // - TW_81_F32

/* Twiddles used in Radix-5 FFT */
const static ne10_fft_cpx_float32_t TW_5A_F32 =
static const ne10_fft_cpx_float32_t TW_5A_F32 =
{
0.309016994374947, // cos (2 * pi / 5)
-0.951056516295154 // - sin (2 * pi / 5)
};
const static ne10_fft_cpx_int32_t TW_5A_S32 =
static const ne10_fft_cpx_int32_t TW_5A_S32 =
{
663608942, // round (TW_5A_F32.r * 2^31)
-2042378317 // round (TW_5A_F32.i * 2^31)
};

const static ne10_fft_cpx_float32_t TW_5B_F32 =
static const ne10_fft_cpx_float32_t TW_5B_F32 =
{
-0.809016994374947, // cos (4 * pi / 5)
-0.587785252292473 // - sin (4 * pi / 5)
};
const static ne10_fft_cpx_int32_t TW_5B_S32 =
static const ne10_fft_cpx_int32_t TW_5B_S32 =
{
-1737350766, // round (TW_5B_F32.r * 2^31)
-1262259218 // round (TW_5B_F32.i * 2^31)
};

/* Twiddles used in Radix-3 FFT */
const static ne10_float32_t TW_3I_F32 = 0.866025403784439; // sqrt (3) / 2
const static ne10_float32_t TW_3IN_F32 = - 0.866025403784439; // - TW_3IN_F32
const static ne10_int32_t TW_3I_S32 = 1859775393; // round (TW_3I_F32 * 2^31)
const static ne10_int32_t TW_3IN_S32 = -1859775393; // round (TW_3IN_F32 * 2^31)
static const ne10_float32_t TW_3I_F32 = 0.866025403784439; // sqrt (3) / 2
static const ne10_float32_t TW_3IN_F32 = - 0.866025403784439; // - TW_3IN_F32
static const ne10_int32_t TW_3I_S32 = 1859775393; // round (TW_3I_F32 * 2^31)
static const ne10_int32_t TW_3IN_S32 = -1859775393; // round (TW_3IN_F32 * 2^31)

#endif // NE10_FFT_COMMON_VARIBLES_H
2 changes: 1 addition & 1 deletion modules/dsp/NE10_fft_generic_float32.h
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ static inline void FFT8_FCU (ne10_fft_cpx_float32_t out[8],
{
ne10_fft_cpx_float32_t s[8];

const static ne10_fft_cpx_float32_t TW_8[4] = {
static const ne10_fft_cpx_float32_t TW_8[4] = {
{ 1.00000, 0.00000 },
{ 0.70711, -0.70711 },
{ 0.00000, -1.00000 },
Expand Down
2 changes: 1 addition & 1 deletion modules/dsp/NE10_fft_generic_float32.neonintrinsic.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -343,7 +343,7 @@ static inline void NE10_FFT8_FUC_NEON_F32 (CPLX out[8],
const CPLX in[8])
{
CPLX s[8];
const static ne10_fft_cpx_float32_t TW_8[4] =
static const ne10_fft_cpx_float32_t TW_8[4] =
{
{ 1.00000, 0.00000 },
{ 0.70711, -0.70711 },
Expand Down