1
0
Fork 0
forked from len0rd/rockbox

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
This commit is contained in:
Nils Wallménius 2011-06-05 13:12:51 +00:00
parent 9f65f2b6ad
commit 965113ed50
4 changed files with 38 additions and 5 deletions

View file

@ -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; \