Commit 43a8c201 authored by mru's avatar mru

ARM: ARMv6 optimised MULH

git-svn-id: file:///var/local/repositories/ffmpeg/trunk@14243 9553f0bf-9b14-0410-a0b8-cfaf0461ba5b
parent fef5baea
...@@ -33,10 +33,20 @@ ...@@ -33,10 +33,20 @@
hi; }) hi; })
#endif #endif
#ifdef HAVE_ARMV6
static inline av_const int MULH(int a, int b)
{
int r;
asm ("smmul %0, %1, %2" : "=r"(r) : "r"(a), "r"(b));
return r;
}
#define MULH MULH
#else
#define MULH(a, b) \ #define MULH(a, b) \
({ int lo, hi;\ ({ int lo, hi;\
asm ("smull %0, %1, %2, %3" : "=&r"(lo), "=&r"(hi) : "r"(b), "r"(a));\ asm ("smull %0, %1, %2, %3" : "=&r"(lo), "=&r"(hi) : "r"(b), "r"(a));\
hi; }) hi; })
#endif
#if defined(HAVE_ARMV5TE) #if defined(HAVE_ARMV5TE)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment