summaryrefslogtreecommitdiff
path: root/apps/codecs/libwma/wmafixed.c
diff options
context:
space:
mode:
Diffstat (limited to 'apps/codecs/libwma/wmafixed.c')
-rw-r--r--apps/codecs/libwma/wmafixed.c25
1 files changed, 1 insertions, 24 deletions
diff --git a/apps/codecs/libwma/wmafixed.c b/apps/codecs/libwma/wmafixed.c
index 45a827af15..7c38009754 100644
--- a/apps/codecs/libwma/wmafixed.c
+++ b/apps/codecs/libwma/wmafixed.c
@@ -53,30 +53,8 @@ fixed64 Fixed32To64(fixed32 x)
53/*Sign-15.16 format */ 53/*Sign-15.16 format */
54#ifdef CPU_ARM 54#ifdef CPU_ARM
55/* these are defines in wmafixed.h*/ 55/* these are defines in wmafixed.h*/
56
57
58#elif defined(CPU_COLDFIRE) 56#elif defined(CPU_COLDFIRE)
59inline int32_t fixmul32(int32_t x, int32_t y) 57
60{
61#if PRECISION != 16
62#warning Coldfire fixmul32() only works for PRECISION == 16
63#endif
64 int32_t t1;
65 asm (
66 "mac.l %[x], %[y], %%acc0 \n" /* multiply */
67 "mulu.l %[y], %[x] \n" /* get lower half, avoid emac stall */
68 "movclr.l %%acc0, %[t1] \n" /* get higher half */
69 "lsr.l #1, %[t1] \n"
70 "move.w %[t1], %[x] \n"
71 "swap %[x] \n"
72 : /* outputs */
73 [t1]"=&d"(t1),
74 [x] "+d" (x)
75 : /* inputs */
76 [y] "d" (y)
77 );
78 return x;
79}
80#else 58#else
81 59
82fixed32 fixmul32(fixed32 x, fixed32 y) 60fixed32 fixmul32(fixed32 x, fixed32 y)
@@ -91,7 +69,6 @@ fixed32 fixmul32(fixed32 x, fixed32 y)
91} 69}
92 70
93 71
94
95/* 72/*
96 Special fixmul32 that does a 16.16 x 1.31 multiply that returns a 16.16 value. 73 Special fixmul32 that does a 16.16 x 1.31 multiply that returns a 16.16 value.
97 this is needed because the fft constants are all normalized to be less then 1 74 this is needed because the fft constants are all normalized to be less then 1