ARM: disable ff_vector_fmul_vfp on VFPv3 systems
authorMans Rullgard <mans@mansr.com>
Fri, 27 May 2011 19:18:26 +0000 (20:18 +0100)
committerMans Rullgard <mans@mansr.com>
Fri, 27 May 2011 19:33:06 +0000 (20:33 +0100)
This function uses old-style vector operations deprecated in VFPv3.
Some implementations, e.g. Cortex-A9, support them only through
slow software emulation.  Cortex-A8 does have this functionality
in hardware, but as it also has NEON, this function is not used
there regardless.

Signed-off-by: Mans Rullgard <mans@mansr.com>
libavcodec/arm/dsputil_init_vfp.c

index 3928911..9cda890 100644 (file)
@@ -28,6 +28,7 @@ void ff_vector_fmul_reverse_vfp(float *dst, const float *src0,
 
 void ff_dsputil_init_vfp(DSPContext* c, AVCodecContext *avctx)
 {
-    c->vector_fmul = ff_vector_fmul_vfp;
+    if (!HAVE_VFPV3)
+        c->vector_fmul = ff_vector_fmul_vfp;
     c->vector_fmul_reverse = ff_vector_fmul_reverse_vfp;
 }