[MPlayer-cvslog] r29077 - in trunk/libmpcodecs: vf_filmdint.c vf_ilpack.c vf_noise.c vf_yadif.c
reimar
subversion at mplayerhq.hu
Fri Mar 27 21:34:55 CET 2009
Author: reimar
Date: Fri Mar 27 21:34:55 2009
New Revision: 29077
Log:
Use x86_reg instead of long in several video filters to fix compilation on MinGW64.
Modified:
trunk/libmpcodecs/vf_filmdint.c
trunk/libmpcodecs/vf_ilpack.c
trunk/libmpcodecs/vf_noise.c
trunk/libmpcodecs/vf_yadif.c
Modified: trunk/libmpcodecs/vf_filmdint.c
==============================================================================
--- trunk/libmpcodecs/vf_filmdint.c Fri Mar 27 21:33:13 2009 (r29076)
+++ trunk/libmpcodecs/vf_filmdint.c Fri Mar 27 21:34:55 2009 (r29077)
@@ -424,7 +424,7 @@ block_metrics_faster_c(unsigned char *a,
"paddusw %%mm2, %%mm7\n\t" \
"paddusw %%mm1, %%mm7\n\t" \
: "=r" (a), "=r" (b) \
- : "r"((long)as), "r"((long)bs), "m" (ones), "0"(a), "1"(b), "X"(*a), "X"(*b) \
+ : "r"((x86_reg)as), "r"((x86_reg)bs), "m" (ones), "0"(a), "1"(b), "X"(*a), "X"(*b) \
); \
} while (--lines);
@@ -466,8 +466,8 @@ block_metrics_mmx2(unsigned char *a, uns
mp_msg(MSGT_VFILTER, MSGL_FATAL, "block_metrics_mmx2: internal error\n");
#else
static const unsigned long long ones = 0x0101010101010101ull;
- unsigned long interlaced;
- unsigned long prefetch_line = (((long)a>>3) & 7) + 10;
+ x86_reg interlaced;
+ x86_reg prefetch_line = (((long)a>>3) & 7) + 10;
#ifdef DEBUG
struct frame_stats ts = *s;
#endif
@@ -633,7 +633,7 @@ dint_copy_line_mmx2(unsigned char *dst,
"por %%mm3, %%mm1 \n\t" /* avg if >= threshold */
"movq %%mm1, (%2,%4) \n\t"
: /* no output */
- : "r" (a), "r" (bos), "r" (dst), "r" ((long)ss), "r" ((long)ds), "r" (cos)
+ : "r" (a), "r" ((x86_reg)bos), "r" ((x86_reg)dst), "r" ((x86_reg)ss), "r" ((x86_reg)ds), "r" ((x86_reg)cos)
);
a += 8;
dst += 8;
Modified: trunk/libmpcodecs/vf_ilpack.c
==============================================================================
--- trunk/libmpcodecs/vf_ilpack.c Fri Mar 27 21:33:13 2009 (r29076)
+++ trunk/libmpcodecs/vf_ilpack.c Fri Mar 27 21:34:55 2009 (r29077)
@@ -187,7 +187,7 @@ static void pack_li_0_MMX(unsigned char
:
: "S" (y), "D" (dst), "a" (u), "b" (v), "c" (w/16),
#if ARCH_X86_64
- "d" ((long)us), "r" ((long)vs)
+ "d" ((x86_reg)us), "r" ((x86_reg)vs)
#else
"d" (&us)
#endif
@@ -299,7 +299,7 @@ static void pack_li_1_MMX(unsigned char
:
: "S" (y), "D" (dst), "a" (u), "b" (v), "c" (w/16),
#if ARCH_X86_64
- "d" ((long)us), "r" ((long)vs)
+ "d" ((x86_reg)us), "r" ((x86_reg)vs)
#else
"d" (&us)
#endif
Modified: trunk/libmpcodecs/vf_noise.c
==============================================================================
--- trunk/libmpcodecs/vf_noise.c Fri Mar 27 21:33:13 2009 (r29076)
+++ trunk/libmpcodecs/vf_noise.c Fri Mar 27 21:34:55 2009 (r29077)
@@ -147,7 +147,7 @@ static int8_t *initNoise(FilterParam *fp
#if HAVE_MMX
static inline void lineNoise_MMX(uint8_t *dst, uint8_t *src, int8_t *noise, int len, int shift){
- long mmx_len= len&(~7);
+ x86_reg mmx_len= len&(~7);
noise+=shift;
__asm__ volatile(
@@ -176,7 +176,7 @@ static inline void lineNoise_MMX(uint8_t
//duplicate of previous except movntq
#if HAVE_MMX2
static inline void lineNoise_MMX2(uint8_t *dst, uint8_t *src, int8_t *noise, int len, int shift){
- long mmx_len= len&(~7);
+ x86_reg mmx_len= len&(~7);
noise+=shift;
__asm__ volatile(
@@ -218,7 +218,7 @@ static inline void lineNoise_C(uint8_t *
#if HAVE_MMX
static inline void lineNoiseAvg_MMX(uint8_t *dst, uint8_t *src, int len, int8_t **shift){
- long mmx_len= len&(~7);
+ x86_reg mmx_len= len&(~7);
__asm__ volatile(
"mov %5, %%"REG_a" \n\t"
Modified: trunk/libmpcodecs/vf_yadif.c
==============================================================================
--- trunk/libmpcodecs/vf_yadif.c Fri Mar 27 21:33:13 2009 (r29076)
+++ trunk/libmpcodecs/vf_yadif.c Fri Mar 27 21:34:55 2009 (r29077)
@@ -247,8 +247,8 @@ static void filter_line_mmx2(struct vf_p
:[prev] "r"(prev),\
[cur] "r"(cur),\
[next] "r"(next),\
- [prefs]"r"((long)refs),\
- [mrefs]"r"((long)-refs),\
+ [prefs]"r"((x86_reg)refs),\
+ [mrefs]"r"((x86_reg)-refs),\
[pw1] "m"(pw_1),\
[pb1] "m"(pb_1),\
[mode] "g"(mode)\
More information about the MPlayer-cvslog
mailing list