summaryrefslogtreecommitdiff
path: root/apps/codecs/libtremor/asm_mcf5249.h
diff options
context:
space:
mode:
Diffstat (limited to 'apps/codecs/libtremor/asm_mcf5249.h')
-rw-r--r--apps/codecs/libtremor/asm_mcf5249.h64
1 files changed, 0 insertions, 64 deletions
diff --git a/apps/codecs/libtremor/asm_mcf5249.h b/apps/codecs/libtremor/asm_mcf5249.h
index 224a861afd..e4f76ea411 100644
--- a/apps/codecs/libtremor/asm_mcf5249.h
+++ b/apps/codecs/libtremor/asm_mcf5249.h
@@ -70,70 +70,6 @@ static inline ogg_int32_t MULT31_SHIFT15(ogg_int32_t x, ogg_int32_t y) {
70 return r; 70 return r;
71} 71}
72 72
73
74static inline
75void XPROD31(ogg_int32_t a, ogg_int32_t b,
76 ogg_int32_t t, ogg_int32_t v,
77 ogg_int32_t *x, ogg_int32_t *y)
78{
79 asm volatile ("mac.l %[a], %[t], %%acc0;"
80 "mac.l %[b], %[v], %%acc0;"
81 "mac.l %[b], %[t], %%acc1;"
82 "msac.l %[a], %[v], %%acc1;"
83 "movclr.l %%acc0, %[a];"
84 "move.l %[a], (%[x]);"
85 "movclr.l %%acc1, %[a];"
86 "move.l %[a], (%[y]);"
87 : [a] "+&r" (a)
88 : [x] "a" (x), [y] "a" (y),
89 [b] "r" (b), [t] "r" (t), [v] "r" (v)
90 : "cc", "memory");
91}
92
93
94static inline
95void XNPROD31(ogg_int32_t a, ogg_int32_t b,
96 ogg_int32_t t, ogg_int32_t v,
97 ogg_int32_t *x, ogg_int32_t *y)
98{
99 asm volatile ("mac.l %[a], %[t], %%acc0;"
100 "msac.l %[b], %[v], %%acc0;"
101 "mac.l %[b], %[t], %%acc1;"
102 "mac.l %[a], %[v], %%acc1;"
103 "movclr.l %%acc0, %[a];"
104 "move.l %[a], (%[x]);"
105 "movclr.l %%acc1, %[a];"
106 "move.l %[a], (%[y]);"
107 : [a] "+&r" (a)
108 : [x] "a" (x), [y] "a" (y),
109 [b] "r" (b), [t] "r" (t), [v] "r" (v)
110 : "cc", "memory");
111}
112
113
114#if 0 /* canonical Tremor definition */
115#define XPROD32(_a, _b, _t, _v, _x, _y) \
116 { (_x)=MULT32(_a,_t)+MULT32(_b,_v); \
117 (_y)=MULT32(_b,_t)-MULT32(_a,_v); }
118#endif
119
120/* this could lose the LSB by overflow, but i don't think it'll ever happen.
121 if anyone think they can hear a bug caused by this, please try the above
122 version. */
123#define XPROD32(_a, _b, _t, _v, _x, _y) \
124 asm volatile ("mac.l %[a], %[t], %%acc0;" \
125 "mac.l %[b], %[v], %%acc0;" \
126 "mac.l %[b], %[t], %%acc1;" \
127 "msac.l %[a], %[v], %%acc1;" \
128 "movclr.l %%acc0, %[x];" \
129 "asr.l #1, %[x];" \
130 "movclr.l %%acc1, %[y];" \
131 "asr.l #1, %[y];" \
132 : [x] "=&d" (_x), [y] "=&d" (_y) \
133 : [a] "r" (_a), [b] "r" (_b), \
134 [t] "r" (_t), [v] "r" (_v) \
135 : "cc");
136
137#ifndef _V_VECT_OPS 73#ifndef _V_VECT_OPS
138#define _V_VECT_OPS 74#define _V_VECT_OPS
139 75