Index: Makefile
===================================================================
RCS file: /cvsroot/ffmpeg/ffmpeg/libavcodec/Makefile,v
retrieving revision 1.126
diff -u -r1.126 Makefile
--- Makefile 14 Nov 2003 05:42:01 -0000 1.126
+++ Makefile 1 Dec 2003 14:33:07 -0000
@@ -151,6 +151,11 @@
OBJS+= sh4/idct_sh4.o sh4/dsputil_sh4.o sh4/dsputil_align.o
endif
+ifeq ($(TARGET_ARCH_SPARC),yes)
+OBJS+=sparc/dsputil_vis.o
+CFLAGS+= -mcpu=ultrasparc -mtune=ultrasparc
+endif
+
SRCS := $(OBJS:.o=.c) $(ASM_OBJS:.o=.S)
OBJS := $(OBJS) $(ASM_OBJS)
Index: dsputil.c
===================================================================
RCS file: /cvsroot/ffmpeg/ffmpeg/libavcodec/dsputil.c,v
retrieving revision 1.89
diff -u -r1.89 dsputil.c
--- dsputil.c 3 Nov 2003 13:26:21 -0000 1.89
+++ dsputil.c 1 Dec 2003 14:33:16 -0000
@@ -3058,6 +3058,9 @@
#ifdef HAVE_MLIB
dsputil_init_mlib(c, avctx);
#endif
+#ifdef ARCH_SPARC
+ dsputil_init_vis(c,avctx);
+#endif
#ifdef ARCH_ALPHA
dsputil_init_alpha(c, avctx);
#endif
Index: dsputil.h
===================================================================
RCS file: /cvsroot/ffmpeg/ffmpeg/libavcodec/dsputil.h,v
retrieving revision 1.78
diff -u -r1.78 dsputil.h
--- dsputil.h 4 Nov 2003 19:35:43 -0000 1.78
+++ dsputil.h 1 Dec 2003 14:33:17 -0000
@@ -154,7 +154,7 @@
/**
* Halfpel motion compensation with rounding (a+b+1)>>1.
* this is an array[4][4] of motion compensation funcions for 4
- * horizontal blocksizes (2,4,8,16) and the 4 halfpel positions
+ * horizontal blocksizes (16,8,4,2) and the 4 halfpel positions
* *pixels_tab[ 0->16xH 1->8xH ][ xhalfpel + 2*yhalfpel ]
* @param block destination where the result is stored
* @param pixels source
@@ -364,6 +364,12 @@
#define __align8 __attribute__ ((aligned (8)))
void dsputil_init_mlib(DSPContext* c, AVCodecContext *avctx);
+
+#elif defined(ARCH_SPARC)
+
+/* SPARC/VIS IDCT needs 8-byte aligned DCT blocks */
+#define __align8 __attribute__ ((aligned (8)))
+void dsputil_init_vis(DSPContext* c, AVCodecContext *avctx);
#elif defined(ARCH_ALPHA)