summaryrefslogtreecommitdiffstats
path: root/mp3lib
diff options
context:
space:
mode:
authorreimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2>2009-01-16 09:21:21 +0000
committerreimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2>2009-01-16 09:21:21 +0000
commit93d598c7b2d6f71fa6381829dc6ec3610ed322e8 (patch)
treecfb70dc87a86bbb17b02e26e9ff614fe53345463 /mp3lib
parent452cda5332e48c77ae5a5594eff3f57d54ded30c (diff)
downloadmpv-93d598c7b2d6f71fa6381829dc6ec3610ed322e8.tar.bz2
mpv-93d598c7b2d6f71fa6381829dc6ec3610ed322e8.tar.xz
Lots and lots of #ifdef ARCH_... -> #if ARCH_...
and #ifdef HAVE_MMX etc -> #if HAVE_MMX. There might be still more that need to be fixed. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28325 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'mp3lib')
-rw-r--r--mp3lib/decod386.c4
-rw-r--r--mp3lib/sr1.c22
2 files changed, 14 insertions, 12 deletions
diff --git a/mp3lib/decod386.c b/mp3lib/decod386.c
index bda2a94bb6..50485cdc20 100644
--- a/mp3lib/decod386.c
+++ b/mp3lib/decod386.c
@@ -102,7 +102,7 @@ static int synth_1to1_mono2stereo(real *bandPtr,unsigned char *samples,int *pnt)
static synth_func_t synth_func;
-#ifdef HAVE_ALTIVEC
+#if HAVE_ALTIVEC
#define dct64_base(a,b,c) if(gCpuCaps.hasAltiVec) dct64_altivec(a,b,c); else dct64(a,b,c)
#else /* HAVE_ALTIVEC */
#define dct64_base(a,b,c) dct64(a,b,c)
@@ -121,7 +121,7 @@ static int synth_1to1(real *bandPtr,int channel,unsigned char *out,int *pnt)
*pnt += 128;
/* optimized for x86 */
-#ifdef ARCH_X86
+#if ARCH_X86
if ( synth_func )
{
// printf("Calling %p, bandPtr=%p channel=%d samples=%p\n",synth_func,bandPtr,channel,samples);
diff --git a/mp3lib/sr1.c b/mp3lib/sr1.c
index d31998f586..31a4a99a49 100644
--- a/mp3lib/sr1.c
+++ b/mp3lib/sr1.c
@@ -27,10 +27,12 @@
#include "libvo/fastmemcpy.h"
-#ifdef ARCH_X86_64
+#if ARCH_X86_64
// 3DNow! and 3DNow!Ext routines don't compile under AMD64
#undef HAVE_3DNOW
#undef HAVE_3DNOWEX
+#define HAVE_3DNOW 0
+#define HAVE_3DNOWEX 0
#endif
//static FILE* mp3_file=NULL;
@@ -134,7 +136,7 @@ LOCAL unsigned int getbits_fast(short number_of_bits)
// if(MP3_frames>=7741) printf("getbits_fast: bits=%d bitsleft=%d wordptr=%x\n",number_of_bits,bitsleft,wordpointer);
if((bitsleft-=number_of_bits)<0) return 0;
if(!number_of_bits) return 0;
-#ifdef ARCH_X86
+#if ARCH_X86
rval = bswap_16(*((uint16_t *)wordpointer));
#else
/*
@@ -177,7 +179,7 @@ LOCAL void set_pointer(int backstep)
LOCAL int stream_head_read(unsigned char *hbuf,uint32_t *newhead){
if(mp3_read(hbuf,4) != 4) return FALSE;
-#ifdef ARCH_X86
+#if ARCH_X86
*newhead = bswap_32(*((uint32_t*)hbuf));
#else
/*
@@ -413,7 +415,7 @@ void MP3_Init(void){
make_decode_tables(outscale);
-#ifdef HAVE_MMX
+#if HAVE_MMX
if (gCpuCaps.hasMMX)
{
_has_mmx = 1;
@@ -421,7 +423,7 @@ void MP3_Init(void){
}
#endif
-#ifdef HAVE_3DNOWEX
+#if HAVE_3DNOWEX
if (gCpuCaps.has3DNowExt)
{
dct36_func=dct36_3dnowex;
@@ -430,7 +432,7 @@ void MP3_Init(void){
}
else
#endif
-#ifdef HAVE_3DNOW
+#if HAVE_3DNOW
if (gCpuCaps.has3DNow)
{
dct36_func = dct36_3dnow;
@@ -439,7 +441,7 @@ void MP3_Init(void){
}
else
#endif
-#ifdef HAVE_SSE
+#if HAVE_SSE
if (gCpuCaps.hasSSE)
{
dct64_MMX_func = dct64_sse;
@@ -447,8 +449,8 @@ void MP3_Init(void){
}
else
#endif
-#ifdef ARCH_X86_32
-#ifdef HAVE_MMX
+#if ARCH_X86_32
+#if HAVE_MMX
if (gCpuCaps.hasMMX)
{
dct64_MMX_func = dct64_MMX;
@@ -463,7 +465,7 @@ void MP3_Init(void){
}
else
#endif /* ARCH_X86_32 */
-#ifdef HAVE_ALTIVEC
+#if HAVE_ALTIVEC
if (gCpuCaps.hasAltiVec)
{
mp_msg(MSGT_DECAUDIO,MSGL_V,"mp3lib: using AltiVec optimized decore!\n");