diff options
| author | Nils Wallménius <nils@rockbox.org> | 2010-11-26 10:45:33 +0000 |
|---|---|---|
| committer | Nils Wallménius <nils@rockbox.org> | 2010-11-26 10:45:33 +0000 |
| commit | b397fe5ae373e3b62fee9150ab786c344c2084cd (patch) | |
| tree | edb4b72f91a5d2fbbb5bd6b523e07f2debdeb344 /apps/codecs | |
| parent | c7e512248388a8196c3b8e5602536f9c85eeb043 (diff) | |
| download | rockbox-b397fe5ae373e3b62fee9150ab786c344c2084cd.zip rockbox-b397fe5ae373e3b62fee9150ab786c344c2084cd.tar.gz rockbox-b397fe5ae373e3b62fee9150ab786c344c2084cd.tar.bz2 rockbox-b397fe5ae373e3b62fee9150ab786c344c2084cd.tar.xz | |
libtremor: small tweak to coldfire inline asm function MULT31_SHIFT15, saving one instruction, *tiny* speedup, output unchanged
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@28666 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/codecs')
| -rw-r--r-- | apps/codecs/libtremor/asm_mcf5249.h | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/apps/codecs/libtremor/asm_mcf5249.h b/apps/codecs/libtremor/asm_mcf5249.h index c13255b..621bead 100644 --- a/apps/codecs/libtremor/asm_mcf5249.h +++ b/apps/codecs/libtremor/asm_mcf5249.h @@ -56,11 +56,10 @@ static inline ogg_int32_t MULT31_SHIFT15(ogg_int32_t x, ogg_int32_t y) { asm volatile ("mac.l %[x], %[y], %%acc0;" /* multiply */ "mulu.l %[y], %[x];" /* get lower half, avoid emac stall */ "movclr.l %%acc0, %[r];" /* get higher half */ - "asl.l #8, %[r];" /* hi<<16, plus one free */ - "asl.l #8, %[r];" + "swap %[r];" /* hi<<16, plus one free */ "lsr.l #8, %[x];" /* (unsigned)lo >> 15 */ "lsr.l #7, %[x];" - "or.l %[x], %[r];" /* logical-or results */ + "move.w %[x], %[r];" /* logical-or results */ : [r] "=&d" (r), [x] "+d" (x) : [y] "d" (y) : "cc"); |