mirror of https://git.ffmpeg.org/ffmpeg.git
arm: float_dsp: Propagate cpu_flags to vfp initialization function
This commit is contained in:
parent
bd549cbaac
commit
7ffda66fd5
|
@ -23,7 +23,7 @@
|
||||||
|
|
||||||
#include "libavutil/float_dsp.h"
|
#include "libavutil/float_dsp.h"
|
||||||
|
|
||||||
void ff_float_dsp_init_vfp (AVFloatDSPContext *fdsp);
|
void ff_float_dsp_init_vfp(AVFloatDSPContext *fdsp, int cpu_flags);
|
||||||
void ff_float_dsp_init_neon(AVFloatDSPContext *fdsp);
|
void ff_float_dsp_init_neon(AVFloatDSPContext *fdsp);
|
||||||
|
|
||||||
#endif /* AVUTIL_ARM_FLOAT_DSP_ARM_H */
|
#endif /* AVUTIL_ARM_FLOAT_DSP_ARM_H */
|
||||||
|
|
|
@ -28,7 +28,7 @@ av_cold void ff_float_dsp_init_arm(AVFloatDSPContext *fdsp)
|
||||||
int cpu_flags = av_get_cpu_flags();
|
int cpu_flags = av_get_cpu_flags();
|
||||||
|
|
||||||
if (have_vfp(cpu_flags))
|
if (have_vfp(cpu_flags))
|
||||||
ff_float_dsp_init_vfp(fdsp);
|
ff_float_dsp_init_vfp(fdsp, cpu_flags);
|
||||||
if (have_neon(cpu_flags))
|
if (have_neon(cpu_flags))
|
||||||
ff_float_dsp_init_neon(fdsp);
|
ff_float_dsp_init_neon(fdsp);
|
||||||
}
|
}
|
||||||
|
|
|
@ -29,10 +29,8 @@ void ff_vector_fmul_vfp(float *dst, const float *src0, const float *src1,
|
||||||
void ff_vector_fmul_reverse_vfp(float *dst, const float *src0,
|
void ff_vector_fmul_reverse_vfp(float *dst, const float *src0,
|
||||||
const float *src1, int len);
|
const float *src1, int len);
|
||||||
|
|
||||||
av_cold void ff_float_dsp_init_vfp(AVFloatDSPContext *fdsp)
|
av_cold void ff_float_dsp_init_vfp(AVFloatDSPContext *fdsp, int cpu_flags)
|
||||||
{
|
{
|
||||||
int cpu_flags = av_get_cpu_flags();
|
|
||||||
|
|
||||||
if (!have_vfpv3(cpu_flags))
|
if (!have_vfpv3(cpu_flags))
|
||||||
fdsp->vector_fmul = ff_vector_fmul_vfp;
|
fdsp->vector_fmul = ff_vector_fmul_vfp;
|
||||||
fdsp->vector_fmul_reverse = ff_vector_fmul_reverse_vfp;
|
fdsp->vector_fmul_reverse = ff_vector_fmul_reverse_vfp;
|
||||||
|
|
Loading…
Reference in New Issue