diff options
author | Andree Buschmann <AndreeBuschmann@t-online.de> | 2008-06-14 11:22:31 +0000 |
---|---|---|
committer | Andree Buschmann <AndreeBuschmann@t-online.de> | 2008-06-14 11:22:31 +0000 |
commit | c0951d95b35cd14b2ab09201ae4bdd0daa802305 (patch) | |
tree | a6656e265a0806c73f9296b5a9bb120875dc3af2 /apps/codecs/libmusepack/synth_filter.c | |
parent | 95cd24d5a22c72eec9777acb11784c8f75071cfe (diff) | |
download | rockbox-c0951d95b35cd14b2ab09201ae4bdd0daa802305.tar.gz rockbox-c0951d95b35cd14b2ab09201ae4bdd0daa802305.zip |
Resort operands in mul/smull/mla/smlal to use D[] as second multiplication operand. Additionally do not pre-scale D[] for the 64 Bit precision synthesizer. Through this the 64 Bit multiplication is speed up by 1.5MHz without loss of precision.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@17719 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/codecs/libmusepack/synth_filter.c')
-rw-r--r-- | apps/codecs/libmusepack/synth_filter.c | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/apps/codecs/libmusepack/synth_filter.c b/apps/codecs/libmusepack/synth_filter.c index ae94741368..9c8d27eed2 100644 --- a/apps/codecs/libmusepack/synth_filter.c +++ b/apps/codecs/libmusepack/synth_filter.c | |||
@@ -54,9 +54,16 @@ | |||
54 | 54 | ||
55 | // in this configuration a post-shift by >>1 is needed after synthesis | 55 | // in this configuration a post-shift by >>1 is needed after synthesis |
56 | #else | 56 | #else |
57 | // saturate to +/- 2^31 (= value << (31-17)), D-values are +/- 2^17 | 57 | #if defined(CPU_ARM) |
58 | #define D(value) (value << (14)) | 58 | // do not up-scale D-values to achieve higher speed in smull/mlal |
59 | 59 | // operations. saves ~14/8 = 1.75 cycles per multiplication | |
60 | #define D(value) (value) | ||
61 | |||
62 | // in this configuration a post-shift by >>16 is needed after synthesis | ||
63 | #else | ||
64 | // saturate to +/- 2^31 (= value << (31-17)), D-values are +/- 2^17 | ||
65 | #define D(value) (value << (14)) | ||
66 | #endif | ||
60 | // do not perform pre-shift | 67 | // do not perform pre-shift |
61 | #define MPC_V_PRESHIFT(X) (X) | 68 | #define MPC_V_PRESHIFT(X) (X) |
62 | #endif | 69 | #endif |