diff options
| author | Nils Wallménius <nils@rockbox.org> | 2011-06-05 13:12:51 +0000 |
|---|---|---|
| committer | Nils Wallménius <nils@rockbox.org> | 2011-06-05 13:12:51 +0000 |
| commit | 965113ed5051d3e9e4b563b8da1f5523c5470a76 (patch) | |
| tree | ea3f7922e5075a96e21fa44e4c78f8a0df56c378 /apps/codecs/lib/asm_arm.h | |
| parent | 9f65f2b6adc24964ac3fe03a75616fab96769bb7 (diff) | |
| download | rockbox-965113ed5051d3e9e4b563b8da1f5523c5470a76.zip rockbox-965113ed5051d3e9e4b563b8da1f5523c5470a76.tar.gz rockbox-965113ed5051d3e9e4b563b8da1f5523c5470a76.tar.bz2 rockbox-965113ed5051d3e9e4b563b8da1f5523c5470a76.tar.xz | |
FS#12146: Fix libcook bugs introduced in r22055 by Sean Bartell.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29973 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/codecs/lib/asm_arm.h')
| -rw-r--r-- | apps/codecs/lib/asm_arm.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/apps/codecs/lib/asm_arm.h b/apps/codecs/lib/asm_arm.h index c0f9440..629e47b 100644 --- a/apps/codecs/lib/asm_arm.h +++ b/apps/codecs/lib/asm_arm.h @@ -52,6 +52,17 @@ static inline int32_t MULT31_SHIFT15(int32_t x, int32_t y) { return(hi); } +static inline int32_t MULT31_SHIFT16(int32_t x, int32_t y) { + int32_t lo,hi; + asm volatile("smull %0, %1, %2, %3\n\t" + "movs %0, %0, lsr #16\n\t" + "adc %1, %0, %1, lsl #16\n\t" + : "=&r"(lo),"=&r"(hi) + : "r"(x),"r"(y) + : "cc" ); + return(hi); +} + #define XPROD32(a, b, t, v, x, y) \ { \ int32_t l; \ |