[xiph-commits] r11492 - in trunk/theora: . lib
j at svn.xiph.org
j at svn.xiph.org
Thu Jun 1 07:34:27 PDT 2006
Author: j
Date: 2006-06-01 07:34:22 -0700 (Thu, 01 Jun 2006)
New Revision: 11492
Modified:
trunk/theora/configure.ac
trunk/theora/lib/cpu.c
Log:
- not only check for USE_ASM also define it in configure.ac
- fix a bug that was hidden by that in cpu.c
Modified: trunk/theora/configure.ac
===================================================================
--- trunk/theora/configure.ac 2006-06-01 14:28:50 UTC (rev 11491)
+++ trunk/theora/configure.ac 2006-06-01 14:34:22 UTC (rev 11492)
@@ -115,12 +115,14 @@
if test ! "x$target_vendor" = "xapple"; then
cpu_x86_32=yes
cpu_optimization="32 bit x86"
+ AC_DEFINE([USE_ASM], [], [make use of asm optimization])
fi
;;
x86_64)
cpu_x86_64=yes
cpu_optimization="64 bit x86"
- ;;
+ AC_DEFINE([USE_ASM], [], [make use of asm optimization])
+ ;;
esac
else
cpu_optimization="disabled"
Modified: trunk/theora/lib/cpu.c
===================================================================
--- trunk/theora/lib/cpu.c 2006-06-01 14:28:50 UTC (rev 11491)
+++ trunk/theora/lib/cpu.c 2006-06-01 14:34:22 UTC (rev 11492)
@@ -26,10 +26,10 @@
"cpuid \n\t"
"movl %%ebx,%1 \n\t"
"popq %%rbx"
- : "=a" (*eax),
- "=r" (*ebx),
- "=c" (*ecx),
- "=d" (*edx)
+ : "=a" (*out_eax),
+ "=r" (*out_ebx),
+ "=c" (*out_ecx),
+ "=d" (*out_edx)
: "a" (op)
: "cc");
# elif defined(__i386__)
@@ -37,10 +37,10 @@
"cpuid \n\t"
"movl %%ebx,%1 \n\t"
"popl %%ebx"
- : "=a" (*eax),
- "=r" (*ebx),
- "=c" (*ecx),
- "=d" (*edx)
+ : "=a" (*out_eax),
+ "=r" (*out_ebx),
+ "=c" (*out_ecx),
+ "=d" (*out_edx)
: "a" (op)
: "cc");
# elif defined(WIN32)
@@ -136,6 +136,7 @@
{
ogg_uint32_t cpu_flags = cpu_get_flags();
+#ifdef DEBUG
if (cpu_flags) {
TH_DEBUG("vectorized instruction sets supported:");
if (cpu_flags & CPU_X86_MMX) TH_DEBUG(" mmx");
@@ -146,6 +147,7 @@
if (cpu_flags & CPU_X86_3DNOWEXT) TH_DEBUG(" 3dnowext");
TH_DEBUG("\n");
}
+#endif
return cpu_flags;
}
More information about the commits
mailing list