Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mumble-voip/speexdsp.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKarl Tomlinson <karlt+@karlt.net>2020-08-29 03:12:56 +0300
committerRalph Giles <giles@thaumas.net>2020-10-02 19:23:27 +0300
commitdc6394e975ec00618a90a38bfd95b28b8e48405b (patch)
tree5a7e386a304e3fdb45f1cbab58bc1d2800c10d89
parent2f852101483cefd8db46d127b73734988d8bb224 (diff)
fixed-point: Remove unused MULT16_32_Q1[1-4] macros and inlines
-rw-r--r--libspeexdsp/arch.h4
-rw-r--r--libspeexdsp/fixed_arm4.h13
-rw-r--r--libspeexdsp/fixed_arm5e.h18
-rw-r--r--libspeexdsp/fixed_bfin.h35
-rw-r--r--libspeexdsp/fixed_debug.h5
-rw-r--r--libspeexdsp/fixed_generic.h6
6 files changed, 0 insertions, 81 deletions
diff --git a/libspeexdsp/arch.h b/libspeexdsp/arch.h
index 4449751..0b2accb 100644
--- a/libspeexdsp/arch.h
+++ b/libspeexdsp/arch.h
@@ -180,13 +180,9 @@ typedef float spx_word32_t;
#define MULT16_16(a,b) ((spx_word32_t)(a)*(spx_word32_t)(b))
#define MAC16_16(c,a,b) ((c)+(spx_word32_t)(a)*(spx_word32_t)(b))
-#define MULT16_32_Q11(a,b) ((a)*(b))
-#define MULT16_32_Q13(a,b) ((a)*(b))
-#define MULT16_32_Q14(a,b) ((a)*(b))
#define MULT16_32_Q15(a,b) ((a)*(b))
#define MULT16_32_P15(a,b) ((a)*(b))
-#define MAC16_32_Q11(c,a,b) ((c)+(a)*(b))
#define MAC16_32_Q15(c,a,b) ((c)+(a)*(b))
#define MAC16_16_Q11(c,a,b) ((c)+(a)*(b))
diff --git a/libspeexdsp/fixed_arm4.h b/libspeexdsp/fixed_arm4.h
index 223478c..a7040b8 100644
--- a/libspeexdsp/fixed_arm4.h
+++ b/libspeexdsp/fixed_arm4.h
@@ -35,19 +35,6 @@
#ifndef FIXED_ARM4_H
#define FIXED_ARM4_H
-#undef MULT16_32_Q14
-static inline spx_word32_t MULT16_32_Q14(spx_word16_t x, spx_word32_t y) {
- int res;
- int dummy;
- asm (
- "smull %0,%1,%2,%3 \n\t"
- "mov %0, %0, lsr #14 \n\t"
- "add %0, %0, %1, lsl #18 \n\t"
- : "=&r"(res), "=&r" (dummy)
- : "r"(y),"r"((int)x));
- return(res);
-}
-
#undef MULT16_32_Q15
static inline spx_word32_t MULT16_32_Q15(spx_word16_t x, spx_word32_t y) {
int res;
diff --git a/libspeexdsp/fixed_arm5e.h b/libspeexdsp/fixed_arm5e.h
index aa565ef..15c6d5d 100644
--- a/libspeexdsp/fixed_arm5e.h
+++ b/libspeexdsp/fixed_arm5e.h
@@ -71,24 +71,6 @@ static inline spx_word32_t MAC16_32_Q15(spx_word32_t a, spx_word16_t x, spx_word
return(res);
}
-#undef MULT16_32_Q11
-static inline spx_word32_t MULT16_32_Q11(spx_word16_t x, spx_word32_t y) {
- int res;
- asm ("smulwb %0,%1,%2;\n"
- : "=&r"(res)
- : "%r"(y<<5),"r"(x));
- return(res);
-}
-
-#undef MAC16_32_Q11
-static inline spx_word32_t MAC16_32_Q11(spx_word32_t a, spx_word16_t x, spx_word32_t y) {
- int res;
- asm ("smlawb %0,%1,%2,%3;\n"
- : "=&r"(res)
- : "%r"(y<<5),"r"(x),"r"(a));
- return(res);
-}
-
#undef DIV32_16
static inline short DIV32_16(int a, int b)
{
diff --git a/libspeexdsp/fixed_bfin.h b/libspeexdsp/fixed_bfin.h
index 646a483..9a54d64 100644
--- a/libspeexdsp/fixed_bfin.h
+++ b/libspeexdsp/fixed_bfin.h
@@ -138,39 +138,4 @@ static inline spx_word32_t MAC16_32_Q15(spx_word32_t c, spx_word16_t a, spx_word
return res;
}
-#undef MULT16_32_Q14
-static inline spx_word32_t MULT16_32_Q14(spx_word16_t a, spx_word32_t b)
-{
- spx_word32_t res;
- __asm__
- (
- "%2 <<= 1;\n\t"
- "A1 = %1.L*%2.L (M);\n\t"
- "A1 = A1 >>> 15;\n\t"
- "%0 = (A1 += %1.L*%2.H);\n\t"
- : "=W" (res), "=d" (a), "=d" (b)
- : "1" (a), "2" (b)
- : "A1", "ASTAT"
- );
- return res;
-}
-
-#undef MAC16_32_Q14
-static inline spx_word32_t MAC16_32_Q14(spx_word32_t c, spx_word16_t a, spx_word32_t b)
-{
- spx_word32_t res;
- __asm__
- (
- "%1 <<= 1;\n\t"
- "A1 = %2.L*%1.L (M);\n\t"
- "A1 = A1 >>> 15;\n\t"
- "%0 = (A1 += %2.L*%1.H);\n\t"
- "%0 = %0 + %4;\n\t"
- : "=&W" (res), "=&d" (b)
- : "d" (a), "1" (b), "d" (c)
- : "A1", "ASTAT"
- );
- return res;
-}
-
#endif
diff --git a/libspeexdsp/fixed_debug.h b/libspeexdsp/fixed_debug.h
index 4d5fe11..8b2f2ef 100644
--- a/libspeexdsp/fixed_debug.h
+++ b/libspeexdsp/fixed_debug.h
@@ -305,11 +305,6 @@ static inline int MULT16_32_PX(int a, long long b, int Q)
}
-#define MULT16_32_Q11(a,b) MULT16_32_QX(a,b,11)
-#define MAC16_32_Q11(c,a,b) ADD32((c),MULT16_32_Q11((a),(b)))
-#define MULT16_32_Q12(a,b) MULT16_32_QX(a,b,12)
-#define MULT16_32_Q13(a,b) MULT16_32_QX(a,b,13)
-#define MULT16_32_Q14(a,b) MULT16_32_QX(a,b,14)
#define MULT16_32_Q15(a,b) MULT16_32_QX(a,b,15)
#define MULT16_32_P15(a,b) MULT16_32_PX(a,b,15)
#define MAC16_32_Q15(c,a,b) ADD32((c),MULT16_32_Q15((a),(b)))
diff --git a/libspeexdsp/fixed_generic.h b/libspeexdsp/fixed_generic.h
index 12d27aa..64f65be 100644
--- a/libspeexdsp/fixed_generic.h
+++ b/libspeexdsp/fixed_generic.h
@@ -75,12 +75,6 @@
#define MULT16_16(a,b) (((spx_word32_t)(spx_word16_t)(a))*((spx_word32_t)(spx_word16_t)(b)))
#define MAC16_16(c,a,b) (ADD32((c),MULT16_16((a),(b))))
-#define MULT16_32_Q12(a,b) ADD32(MULT16_16((a),SHR((b),12)), SHR(MULT16_16((a),((b)&0x00000fff)),12))
-#define MULT16_32_Q13(a,b) ADD32(MULT16_16((a),SHR((b),13)), SHR(MULT16_16((a),((b)&0x00001fff)),13))
-#define MULT16_32_Q14(a,b) ADD32(MULT16_16((a),SHR((b),14)), SHR(MULT16_16((a),((b)&0x00003fff)),14))
-
-#define MULT16_32_Q11(a,b) ADD32(MULT16_16((a),SHR((b),11)), SHR(MULT16_16((a),((b)&0x000007ff)),11))
-#define MAC16_32_Q11(c,a,b) ADD32(c,ADD32(MULT16_16((a),SHR((b),11)), SHR(MULT16_16((a),((b)&0x000007ff)),11)))
#define MULT16_32_P15(a,b) ADD32(MULT16_16((a),SHR((b),15)), PSHR(MULT16_16((a),((b)&0x00007fff)),15))
#define MULT16_32_Q15(a,b) ADD32(MULT16_16((a),SHR((b),15)), SHR(MULT16_16((a),((b)&0x00007fff)),15))