From: Falk Hueffner <falk.hueffner@student.uni-tuebingen.de>
To: axp-list@redhat.com
Subject: Re: Trouble compiling MPlayer
Date: 19 Sep 2002 12:52:39 +0200 [thread overview]
Message-ID: <87d6ratfns.fsf@student.uni-tuebingen.de> (raw)
In-Reply-To: <3D89991D.8070902@coruscant.htam.net>
Mathieu MILLET <htam@nerim.net> writes:
> I'am having trouble compiling MPLayer that give the following messages :
>
> /tmp/ccynnHuS.s: Assembler messages:
> /tmp/ccynnHuS.s:67: Error: opcode `unpkbw' not supported for target ev56
Heh, it's my fault :) Please try this patch:
diff -u -p -r1.54 Makefile
--- Makefile 5 Sep 2002 10:06:20 -0000 1.54
+++ Makefile 19 Sep 2002 10:44:17 -0000
@@ -69,7 +69,12 @@ endif
ifeq ($(TARGET_ARCH_ALPHA),yes)
OBJS += alpha/dsputil_alpha.o alpha/mpegvideo_alpha.o alpha/motion_est_alpha.o
ASM_OBJS += alpha/dsputil_alpha_asm.o
-CFLAGS += -Wa,-mpca56 -finline-limit=8000 -fforce-addr -freduce-all-givs
+CFLAGS += -finline-limit=8000 -fforce-addr -freduce-all-givs -mcpu=ev4
+alpha/motion_est_alpha.o: alpha/motion_est_alpha.c
+ cpu=`echo "$(CFLAGS)" | sed 's,.*-mcpu=\([a-zA-Z0-9]*\).*,\1,'`; \
+ case x"$$cpu" in xev[45]*) newcpu=pca56;; x) newcpu=pca56;; *) newcpu=$cpu;; esac; \
+ cflags=`echo $(CFLAGS) | sed s,$$cpu,$$newcpu,`; \
+ $(CC) $$cflags -c -o $@ $<
endif
ifeq ($(TARGET_ARCH_POWERPC),yes)
(ugh, ugly, but I cannot think of a better way...)
If you want to optimize these routines for ev56, you could try these:
inline uint64_t perr_emu(uint64_t x, uint64_t y) { /* 14 cycles on ev5 */
uint64_t bytemask, c, minx, miny, minb, maxb, d;
bytemask = zapnot(-1, 0x55); // 0x00ff00ff00ff00ff
c = cmpbge(x, y);
minx = zap(x, c);
miny = zapnot(y, c);
minb = minx | miny;
maxb = minb ^ (x ^ y);
d = maxb - minb;
d = ((d & ~bytemask) >> 8) + (d & bytemask);
d += d >> 32;
d += d >> 16;
d &= 0xffff;
return d;
}
uint64_t unpkbw_emu(uint64_t x) { /* 7 cycles */
uint64_t t;
x = zapnot(x, 0x0f); /* 0000000004030201 */
x |= x << 16; /* 00000403??030201 */
t = zapnot(x, 0x11); /* 0000000300000001 */
x <<= 8; /* 0004030603020100 */
x = zapnot(x, 0x44); /* 0004000000020000 */
return t | x;
}
--
Falk
next prev parent reply other threads:[~2002-09-19 10:52 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-09-19 9:30 Trouble compiling MPlayer Mathieu MILLET
2002-09-19 10:52 ` Falk Hueffner [this message]
2002-09-24 13:34 ` Vakvarju
2002-09-24 15:42 ` Falk Hueffner
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox