diff options
author | David Schleef <ds@schleef.org> | 2005-10-28 17:13:25 +0000 |
---|---|---|
committer | David Schleef <ds@schleef.org> | 2005-10-28 17:13:25 +0000 |
commit | fea6c756ecc5429c82ed37a5714a38942752c87c (patch) | |
tree | a46e36acecbff4b86b95b9221c1b5ae3a82020cd | |
parent | 76febb44bf5d78122e33db532e9e299379c33316 (diff) | |
download | liboil-fea6c756ecc5429c82ed37a5714a38942752c87c.tar.gz |
* liboil/i386/diff8x8_i386.c: (diff8x8_const128_s16_u8_mmx):
Fix problem pulling in global constant.
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | liboil/i386/diff8x8_i386.c | 14 |
2 files changed, 10 insertions, 9 deletions
@@ -1,3 +1,8 @@ +2005-10-28 David Schleef <ds@schleef.org> + + * liboil/i386/diff8x8_i386.c: (diff8x8_const128_s16_u8_mmx): + Fix problem pulling in global constant. + 2005-10-27 David Schleef <ds@schleef.org> * liboil/Makefile.am: Fixups from conflicts in previous commit. diff --git a/liboil/i386/diff8x8_i386.c b/liboil/i386/diff8x8_i386.c index a0dc8ae..7d9eea5 100644 --- a/liboil/i386/diff8x8_i386.c +++ b/liboil/i386/diff8x8_i386.c @@ -35,13 +35,6 @@ OIL_DECLARE_CLASS (diff8x8_s16_u8); OIL_DECLARE_CLASS (diff8x8_const128_s16_u8); OIL_DECLARE_CLASS (diff8x8_average_s16_u8); -static const __attribute__ ((aligned(8),used)) int64_t V128w = 0x0080008000800080LL; - -#ifdef HAVE_LD_UNDERSCORE -# define M(a) "_" #a -#else -# define M(a) #a -#endif static void diff8x8_s16_u8_mmx (int16_t *dest, uint8_t *src1, int ss1, uint8_t *src2, int ss2) @@ -86,11 +79,13 @@ OIL_DEFINE_IMPL_FULL (diff8x8_s16_u8_mmx, diff8x8_s16_u8, OIL_IMPL_FLAG_MMX); static void diff8x8_const128_s16_u8_mmx (int16_t *dest, uint8_t *src1, int ss1) { + const int16_t tmp[4] = { 0x0080, 0x0080, 0x0080, 0x0080 }; + __asm__ __volatile__ ( " .balign 16 \n\t" " pxor %%mm7, %%mm7 \n\t" - " movq "M(V128w)", %%mm1 \n\t" + " movq (%3), %%mm1 \n\t" ".rept 8 \n\t" " movq (%0), %%mm0 \n\t" /* mm0 = FiltPtr */ @@ -111,7 +106,8 @@ diff8x8_const128_s16_u8_mmx (int16_t *dest, uint8_t *src1, int ss1) : "+r" (src1), "+r" (dest) - : "r" (ss1) + : "r" (ss1), + "r" (tmp) : "memory" ); } |