summaryrefslogtreecommitdiff
path: root/libavcodec/mips/mathops.h
diff options
context:
space:
mode:
author周晓勇 <zhouxiaoyong@loongson.cn>2015-05-21 16:31:58 +0800
committerMichael Niedermayer <michaelni@gmx.at>2015-05-21 17:46:33 +0200
commit33e9473366074ee92eecec5f5719734e4a6b4b79 (patch)
tree91c9d1aceb4fe594ea68028a002c03c7a55faf23 /libavcodec/mips/mathops.h
parent818275bbd0477777531fa701cab9fb224055f080 (diff)
avcodec/mips: loongson fix bugs in mathops optimization
the incorrect UMULH, ff_sqrt, MAC64 and MLS64 to be optimized later, delete them just for now. Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/mips/mathops.h')
-rw-r--r--libavcodec/mips/mathops.h51
1 files changed, 0 insertions, 51 deletions
diff --git a/libavcodec/mips/mathops.h b/libavcodec/mips/mathops.h
index cdc7705bad..bb9dc8375a 100644
--- a/libavcodec/mips/mathops.h
+++ b/libavcodec/mips/mathops.h
@@ -43,19 +43,6 @@ static inline av_const int MULH(int a, int b)
return c;
}
-#define UMULH UMULH
-static inline av_const unsigned UMULH(unsigned a, unsigned b)
-{
- unsigned c;
- __asm__ ("dmultu %1, %2 \n\t"
- "mflo %0 \n\t"
- "dsrl %0, %0, 32 \n\t"
- : "=r"(c)
- : "r"(a),"r"(b)
- : "hi", "lo");
- return c;
-}
-
#define mid_pred mid_pred
static inline av_const int mid_pred(int a, int b, int c)
{
@@ -73,44 +60,6 @@ static inline av_const int mid_pred(int a, int b, int c)
return t;
}
-#define ff_sqrt ff_sqrt
-static inline av_const unsigned int ff_sqrt(unsigned int a)
-{
- unsigned int b;
-
- __asm__ ("ctc1 %1, $f0 \n\t"
- "sqrt.s $f2, $f0 \n\t"
- "cvt.w.s $f0, $f2 \n\t"
- "cfc1 %0, $f0 \n\t"
- : "=r"(b)
- : "r"(a));
- return b;
-}
-
-static inline av_const int64_t MAC64(int64_t d, int a, int b)
-{
- int64_t m;
- __asm__ ("dmult %2, %3 \n\t"
- "mflo %1 \n\t"
- "daddu %0, %0, %1 \n\t"
- : "+r"(d), "=&r"(m) : "r"(a), "r"(b)
- : "hi", "lo");
- return d;
-}
-#define MAC64(d, a, b) ((d) = MAC64(d, a, b))
-
-static inline av_const int64_t MLS64(int64_t d, int a, int b)
-{
- int64_t m;
- __asm__ ("dmult %2, %3 \n\t"
- "mflo %1 \n\t"
- "dsubu %0, %0, %1 \n\t"
- : "+r"(d), "=&r"(m) : "r"(a), "r"(b)
- : "hi", "lo");
- return d;
-}
-#define MLS64(d, a, b) ((d) = MLS64(d, a, b))
-
#endif /* HAVE_LOONGSON3 */
#endif /* HAVE_INLINE_ASM */