[FFmpeg-cvslog] r17451 - trunk/libavcodec/fft.c

diego subversion
Thu Feb 19 01:54:59 CET 2009


Author: diego
Date: Thu Feb 19 01:54:59 2009
New Revision: 17451

Log:
Only enable SSE/3DNOW optimizations when they have been enabled at compilation.
Fixes shared build with SSE/3DNOW disabled but MMX and yasm enabled.

Modified:
   trunk/libavcodec/fft.c

Modified: trunk/libavcodec/fft.c
==============================================================================
--- trunk/libavcodec/fft.c	Thu Feb 19 01:47:11 2009	(r17450)
+++ trunk/libavcodec/fft.c	Thu Feb 19 01:54:59 2009	(r17451)
@@ -89,18 +89,18 @@ av_cold int ff_fft_init(FFTContext *s, i
 
 #if HAVE_MMX && HAVE_YASM
     has_vectors = mm_support();
-    if (has_vectors & FF_MM_SSE) {
+    if (has_vectors & FF_MM_SSE && HAVE_SSE) {
         /* SSE for P3/P4/K8 */
         s->imdct_calc  = ff_imdct_calc_sse;
         s->imdct_half  = ff_imdct_half_sse;
         s->fft_permute = ff_fft_permute_sse;
         s->fft_calc    = ff_fft_calc_sse;
-    } else if (has_vectors & FF_MM_3DNOWEXT) {
+    } else if (has_vectors & FF_MM_3DNOWEXT && HAVE_AMD3DNOWEXT) {
         /* 3DNowEx for K7 */
         s->imdct_calc = ff_imdct_calc_3dn2;
         s->imdct_half = ff_imdct_half_3dn2;
         s->fft_calc   = ff_fft_calc_3dn2;
-    } else if (has_vectors & FF_MM_3DNOW) {
+    } else if (has_vectors & FF_MM_3DNOW && HAVE_AMD3DNOW) {
         /* 3DNow! for K6-2/3 */
         s->imdct_calc = ff_imdct_calc_3dn;
         s->imdct_half = ff_imdct_half_3dn;




More information about the ffmpeg-cvslog mailing list