Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.xiph.org/xiph/opus.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/celt/vq.c
diff options
context:
space:
mode:
authorJean-Marc Valin <jmvalin@jmvalin.ca>2011-09-25 08:11:46 +0400
committerJean-Marc Valin <jmvalin@jmvalin.ca>2011-09-25 08:11:46 +0400
commit0da4f238e0771e35dedd12cd5c2c1da6a9374067 (patch)
tree8c91aa47c1578a058180c21810ba3230c61314a7 /celt/vq.c
parent803ec8c6b4d959b6b1df4b2e8f253415c7b4c325 (diff)
Avoiding more left shifts of negative values
Diffstat (limited to 'celt/vq.c')
-rw-r--r--celt/vq.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/celt/vq.c b/celt/vq.c
index bf85f8d2..737916eb 100644
--- a/celt/vq.c
+++ b/celt/vq.c
@@ -137,7 +137,7 @@ static void normalise_residual(int * restrict iy, celt_norm * restrict X,
#ifdef FIXED_POINT
k = celt_ilog2(Ryy)>>1;
#endif
- t = VSHR32(Ryy, (k-7)<<1);
+ t = VSHR32(Ryy, 2*(k-7));
g = MULT16_16_P15(celt_rsqrt_norm(t),gain);
i=0;
@@ -378,7 +378,7 @@ void renormalise_vector(celt_norm *X, int N, opus_val16 gain)
#ifdef FIXED_POINT
k = celt_ilog2(E)>>1;
#endif
- t = VSHR32(E, (k-7)<<1);
+ t = VSHR32(E, 2*(k-7));
g = MULT16_16_P15(celt_rsqrt_norm(t),gain);
xptr = X;