19 |
* along with this program ; if not, write to the Free Software |
* along with this program ; if not, write to the Free Software |
20 |
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
21 |
* |
* |
22 |
* $Id: gmc.c,v 1.8 2008-11-14 15:43:27 Isibaar Exp $ |
* $Id$ |
23 |
* |
* |
24 |
****************************************************************************/ |
****************************************************************************/ |
25 |
|
|
48 |
log2bin(uint32_t value) |
log2bin(uint32_t value) |
49 |
{ |
{ |
50 |
/* Changed by Chenm001 */ |
/* Changed by Chenm001 */ |
51 |
#if !defined(_MSC_VER) |
#if !defined(_MSC_VER) || defined(ARCH_IS_X86_64) |
52 |
int n = 0; |
int n = 0; |
53 |
|
|
54 |
while (value) { |
while (value) { |
385 |
mv->y = RSHIFT(Dsp->Vo<<qpel, 3); |
mv->y = RSHIFT(Dsp->Vo<<qpel, 3); |
386 |
} |
} |
387 |
|
|
388 |
#if defined(ARCH_IS_IA32) |
#if defined(ARCH_IS_IA32) || defined(ARCH_IS_X86_64) |
389 |
/* ************************************************************* |
/* ************************************************************* |
390 |
* MMX core function |
* MMX core function |
391 |
*/ |
*/ |
590 |
Predict_16x16_func = Predict_16x16_C; |
Predict_16x16_func = Predict_16x16_C; |
591 |
Predict_8x8_func = Predict_8x8_C; |
Predict_8x8_func = Predict_8x8_C; |
592 |
|
|
593 |
#if defined(ARCH_IS_IA32) |
#if defined(ARCH_IS_IA32) || defined(ARCH_IS_X86_64) |
594 |
if ((cpu_flags & XVID_CPU_MMX) || (cpu_flags & XVID_CPU_MMXEXT) || |
if ((cpu_flags & XVID_CPU_MMX) || (cpu_flags & XVID_CPU_MMXEXT) || |
595 |
(cpu_flags & XVID_CPU_3DNOW) || (cpu_flags & XVID_CPU_3DNOWEXT) || |
(cpu_flags & XVID_CPU_3DNOW) || (cpu_flags & XVID_CPU_3DNOWEXT) || |
596 |
(cpu_flags & XVID_CPU_SSE) || (cpu_flags & XVID_CPU_SSE2) || |
(cpu_flags & XVID_CPU_SSE) || (cpu_flags & XVID_CPU_SSE2) || |
598 |
{ |
{ |
599 |
Predict_16x16_func = Predict_16x16_mmx; |
Predict_16x16_func = Predict_16x16_mmx; |
600 |
Predict_8x8_func = Predict_8x8_mmx; |
Predict_8x8_func = Predict_8x8_mmx; |
601 |
#if 0 |
|
602 |
if (cpu_flags & XVID_CPU_SSE41) |
if (cpu_flags & XVID_CPU_SSE41) |
603 |
GMC_Core_Lin_8 = xvid_GMC_Core_Lin_8_sse41; |
GMC_Core_Lin_8 = xvid_GMC_Core_Lin_8_sse41; |
604 |
else |
else if (cpu_flags & XVID_CPU_SSE2) |
|
#endif |
|
|
if (cpu_flags & XVID_CPU_SSE2) |
|
605 |
GMC_Core_Lin_8 = xvid_GMC_Core_Lin_8_sse2; |
GMC_Core_Lin_8 = xvid_GMC_Core_Lin_8_sse2; |
606 |
else |
else |
607 |
GMC_Core_Lin_8 = xvid_GMC_Core_Lin_8_mmx; |
GMC_Core_Lin_8 = xvid_GMC_Core_Lin_8_mmx; |