# HG changeset patch # User reimar # Date 1254304152 0 # Node ID 36b60aa6bc756711f6765e2a6cd993e79a9eb5bf # Parent 5bbe554518009187dd6266136e6d6d7692337459 Replace several #ifdef PIC with the more obvious and correct #if !HAVE_EBX_AVAILABLE, since all it does is avoid using ebx. diff -r 5bbe55451800 -r 36b60aa6bc75 x86/dsputil_mmx_avg_template.c --- a/x86/dsputil_mmx_avg_template.c Wed Sep 30 05:49:18 2009 +0000 +++ b/x86/dsputil_mmx_avg_template.c Wed Sep 30 09:49:12 2009 +0000 @@ -96,7 +96,7 @@ "add $16, %2 \n\t" "subl $4, %0 \n\t" "jnz 1b \n\t" -#ifdef PIC //Note "+bm" and "+mb" are buggy too (with gcc 3.2.2 at least) and cannot be used +#if !HAVE_EBX_AVAILABLE //Note "+bm" and "+mb" are buggy too (with gcc 3.2.2 at least) and cannot be used :"+m"(h), "+a"(src1), "+c"(src2), "+d"(dst) #else :"+b"(h), "+a"(src1), "+c"(src2), "+d"(dst) @@ -143,7 +143,7 @@ "add $32, %2 \n\t" "subl $4, %0 \n\t" "jnz 1b \n\t" -#ifdef PIC //Note "+bm" and "+mb" are buggy too (with gcc 3.2.2 at least) and cannot be used +#if !HAVE_EBX_AVAILABLE //Note "+bm" and "+mb" are buggy too (with gcc 3.2.2 at least) and cannot be used :"+m"(h), "+a"(src1), "+c"(src2), "+d"(dst) #else :"+b"(h), "+a"(src1), "+c"(src2), "+d"(dst) @@ -213,7 +213,7 @@ "add $32, %2 \n\t" "subl $4, %0 \n\t" "jnz 1b \n\t" -#ifdef PIC //Note "+bm" and "+mb" are buggy too (with gcc 3.2.2 at least) and cannot be used +#if !HAVE_EBX_AVAILABLE //Note "+bm" and "+mb" are buggy too (with gcc 3.2.2 at least) and cannot be used :"+m"(h), "+a"(src1), "+c"(src2), "+d"(dst) #else :"+b"(h), "+a"(src1), "+c"(src2), "+d"(dst) @@ -268,7 +268,7 @@ "add $16, %2 \n\t" "subl $4, %0 \n\t" "jnz 1b \n\t" -#ifdef PIC //Note "+bm" and "+mb" are buggy too (with gcc 3.2.2 at least) and cannot be used +#if !HAVE_EBX_AVAILABLE //Note "+bm" and "+mb" are buggy too (with gcc 3.2.2 at least) and cannot be used :"+m"(h), "+a"(src1), "+c"(src2), "+d"(dst) #else :"+b"(h), "+a"(src1), "+c"(src2), "+d"(dst) @@ -320,7 +320,7 @@ "add $32, %2 \n\t" "subl $4, %0 \n\t" "jnz 1b \n\t" -#ifdef PIC //Note "+bm" and "+mb" are buggy too (with gcc 3.2.2 at least) and cannot be used +#if !HAVE_EBX_AVAILABLE //Note "+bm" and "+mb" are buggy too (with gcc 3.2.2 at least) and cannot be used :"+m"(h), "+a"(src1), "+c"(src2), "+d"(dst) #else :"+b"(h), "+a"(src1), "+c"(src2), "+d"(dst) @@ -408,7 +408,7 @@ "add $32, %2 \n\t" "subl $2, %0 \n\t" "jnz 1b \n\t" -#ifdef PIC //Note "+bm" and "+mb" are buggy too (with gcc 3.2.2 at least) and cannot be used +#if !HAVE_EBX_AVAILABLE //Note "+bm" and "+mb" are buggy too (with gcc 3.2.2 at least) and cannot be used :"+m"(h), "+a"(src1), "+c"(src2), "+d"(dst) #else :"+b"(h), "+a"(src1), "+c"(src2), "+d"(dst) @@ -462,7 +462,7 @@ "add $32, %2 \n\t" "subl $2, %0 \n\t" "jnz 1b \n\t" -#ifdef PIC //Note "+bm" and "+mb" are buggy too (with gcc 3.2.2 at least) and cannot be used +#if !HAVE_EBX_AVAILABLE //Note "+bm" and "+mb" are buggy too (with gcc 3.2.2 at least) and cannot be used :"+m"(h), "+a"(src1), "+c"(src2), "+d"(dst) #else :"+b"(h), "+a"(src1), "+c"(src2), "+d"(dst) @@ -535,7 +535,7 @@ "add $32, %2 \n\t" "subl $2, %0 \n\t" "jnz 1b \n\t" -#ifdef PIC //Note "+bm" and "+mb" are buggy too (with gcc 3.2.2 at least) and cannot be used +#if !HAVE_EBX_AVAILABLE //Note "+bm" and "+mb" are buggy too (with gcc 3.2.2 at least) and cannot be used :"+m"(h), "+a"(src1), "+c"(src2), "+d"(dst) #else :"+b"(h), "+a"(src1), "+c"(src2), "+d"(dst) diff -r 5bbe55451800 -r 36b60aa6bc75 x86/dsputil_mmx_rnd_template.c --- a/x86/dsputil_mmx_rnd_template.c Wed Sep 30 05:49:18 2009 +0000 +++ b/x86/dsputil_mmx_rnd_template.c Wed Sep 30 09:49:12 2009 +0000 @@ -98,7 +98,7 @@ "add %5, %3 \n\t" "subl $4, %0 \n\t" "jnz 1b \n\t" -#ifdef PIC //Note "+bm" and "+mb" are buggy too (with gcc 3.2.2 at least) and cannot be used +#if !HAVE_EBX_AVAILABLE //Note "+bm" and "+mb" are buggy too (with gcc 3.2.2 at least) and cannot be used :"+m"(h), "+a"(src1), "+c"(src2), "+d"(dst) #else :"+b"(h), "+a"(src1), "+c"(src2), "+d"(dst) @@ -193,7 +193,7 @@ "add $32, %2 \n\t" "subl $2, %0 \n\t" "jnz 1b \n\t" -#ifdef PIC //Note "+bm" and "+mb" are buggy too (with gcc 3.2.2 at least) and cannot be used +#if !HAVE_EBX_AVAILABLE //Note "+bm" and "+mb" are buggy too (with gcc 3.2.2 at least) and cannot be used :"+m"(h), "+a"(src1), "+c"(src2), "+d"(dst) #else :"+b"(h), "+a"(src1), "+c"(src2), "+d"(dst)