[FFmpeg-cvslog] r13957 - in trunk/libavcodec: dct-test.c dsputil.h fft-test.c
astrange
subversion
Wed Jun 25 01:51:17 CEST 2008
Author: astrange
Date: Wed Jun 25 01:51:17 2008
New Revision: 13957
Log:
Define mm_flags/support to be 0 on architectures where they don't exist.
Make sure we don't try to set them if that's the case.
This lets dct-test and fft-test build with --disable-mmx on x86, but not yet on ARM.
Modified:
trunk/libavcodec/dct-test.c
trunk/libavcodec/dsputil.h
trunk/libavcodec/fft-test.c
Modified: trunk/libavcodec/dct-test.c
==============================================================================
--- trunk/libavcodec/dct-test.c (original)
+++ trunk/libavcodec/dct-test.c Wed Jun 25 01:51:17 2008
@@ -531,7 +531,10 @@ int main(int argc, char **argv)
init_fdct();
idct_mmx_init();
+
+#ifndef mm_flags
mm_flags = mm_support();
+#endif
for(i=0;i<256;i++) cropTbl[i + MAX_NEG_CROP] = i;
for(i=0;i<MAX_NEG_CROP;i++) {
Modified: trunk/libavcodec/dsputil.h
==============================================================================
--- trunk/libavcodec/dsputil.h (original)
+++ trunk/libavcodec/dsputil.h Wed Jun 25 01:51:17 2008
@@ -578,6 +578,11 @@ extern int mm_flags;
#define DECLARE_ALIGNED_8(t, v) DECLARE_ALIGNED(16, t, v)
#define STRIDE_ALIGN 16
+#else
+
+#define mm_flags 0
+#define mm_support() 0
+
#endif
#ifndef DECLARE_ALIGNED_8
Modified: trunk/libavcodec/fft-test.c
==============================================================================
--- trunk/libavcodec/fft-test.c (original)
+++ trunk/libavcodec/fft-test.c Wed Jun 25 01:51:17 2008
@@ -186,7 +186,10 @@ int main(int argc, char **argv)
MDCTContext m1, *m = &m1;
int fft_nbits, fft_size;
+#ifndef mm_flags
mm_flags = 0;
+#endif
+
fft_nbits = 9;
for(;;) {
c = getopt(argc, argv, "hsimn:");
More information about the ffmpeg-cvslog
mailing list