Displaying 20 results from an estimated 33 matches for "shl32".
2013 Dec 09
1
incorrect use of MAX16
...x of 16bit. Changing the default definition to take
advantage of this hardware changes the result of that
computation.
Please consider the change below for inclusion in the opus
code base.
/* *tf_estimate = 1 + MIN16(1, sqrt(MAX16(0, tf_max-30))/20); */
- *tf_estimate = celt_sqrt(MAX16(0,
SHL32(MULT16_16(QCONST16(0.0069,14),MIN16(163,tf_max)),14)-QCONST32(0.139,28)));
+ *tf_estimate = celt_sqrt(MAX32(0,
SHL32(MULT16_16(QCONST16(0.0069,14),MIN16(163,tf_max)),14)-QCONST32(0.139,28)));
/*printf("%d %f\n", tf_max, mask_metric);*/
--
2006 Apr 18
2
Major internal changes, TI DSP build change
...b_celp.c/h are changed in this build. What
> I am seeing out of the decoder is an extremely low signal (sample values of
> +/-10, in this build, by build 11126 the output is almost all zeros).
That's quite strange, but I think I figured it out. Could you try
changing the definition of SHL32 in fixed_generic.h from
#define SHR32(a,shift) ((a) >> (shift))
to
#define SHR32(a,shift) (((spx_word32_t)(a)) >> (shift))
This is not the correct fix, but if it does solve the problem, then I
know how to fix it properly (by using EXTEND32) in svn.
> It may be a compiler hiccup in...
2007 Aug 29
2
high-pass filter issues
...filtID=4;
den = Pcoef[filtID]; num = Zcoef[filtID];
/*return;*/
for (i=0;i<len;i++)
{
spx_word16_t yi;
spx_word32_t vout = ADD32(MULT16_16(num[0], x[i]),mem[0]);
yi = EXTRACT16(SATURATE(PSHR32(vout,14),32767));
mem[0] = ADD32(MAC16_16(mem[1], num[1],x[i]),
SHL32(MULT16_32_Q15(-den[1],vout),1));
mem[1] = ADD32(MULT16_16(num[2],x[i]),
SHL32(MULT16_32_Q15(-den[2],vout),1));
y[i] = yi;
}
}
I can step into the function just fine, but when I run it, even just
from the initial variable declarations to the top of that "for" loop I
vect...
2010 Jun 15
2
AEC init crashes
Hello,
I've just caught a strange crash in speex_echo_state_init routine. It
happened only on one WinXP machine, while on others using XP, Vista and
7 everything is fine.
Crash occures in mdf.c line 434: st->spec_average =
DIV32_16(SHL32(EXTEND32(st->frame_size), 15), st->sampling_rate);
Got any ideas or should I provide more information of the OS?
Thanks a lot!
Regards,
Anton A. Shpakovsky
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.xiph.org/pipermail/speex-dev/a...
2007 Dec 12
1
4kbps sounds robotic on TMS320C64
...you test all rates and found 4 kbps to be the only one
problematic? If possible, can you try encoding on one and decoding on
the other, just to see whether the problem is when the encoder or the
decoder? Also, just in case it helps (but I doubt it),
try editing fixed_generic.h and change:
#define SHL32(a,shift) ((a) << (shift))
to
#define SHL32(a,shift) ((spx_int32_t)(a) << (spx_int32_t)(shift))
Cheers,
Jean-Marc
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.xiph.org/pipermail/speex-dev/attachments/20071212/591b9b39/attachment.html
2005 May 26
2
Speex on TI C6x, Problem with TI C5x Patch
...bits. My initial guess would be with the SH[RL]32 and ADD32 functions.
Nice call. The culprit is SHRL32. This is not used in many places, and in
most of those, the operand comes from EXTEND32. The only really suspicious
instances is in lsp.c (lsp_interpolate):
spx_word16_t tmp = DIV32_16(SHL32(1 + subframe,14),nb_subframes);
(subframe is an int)
> I just checked in changes that may fix some bad behavior on 16-bit
> architectures. You might want to try if it fixes the problem. As I said,
> it's not clear yet whether the problem is in fixed_generic.h or if it's
> some...
2006 Apr 19
0
Major internal changes, TI DSP build change
...>> What
>> I am seeing out of the decoder is an extremely low signal (sample values
>> of
>> +/-10, in this build, by build 11126 the output is almost all zeros).
>
> That's quite strange, but I think I figured it out. Could you try
> changing the definition of SHL32 in fixed_generic.h from
> #define SHR32(a,shift) ((a) >> (shift))
> to
> #define SHR32(a,shift) (((spx_word32_t)(a)) >> (shift))
>
> This is not the correct fix, but if it does solve the problem, then I
> know how to fix it properly (by using EXTEND32) in svn.
>
>...
2006 Jul 24
2
Fix for lsp.c for 16-bit platforms (TI C55x DSP)
...eration was broken again. I traced this to build 11522, committed on 5 June. The problem is in lsp.c, function lsp_to_lpc(). The line (lsp.c line 461 in build 11700):
xin = 1<<(QIMP-1); /* 0.5 in QIMP format */
evaluates to zero. The following change corrects the problem:
xin = SHL32(EXTEND32(1), (QIMP-1)); /* 0.5 in QIMP format */
Regards,
Jim Crichton
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.xiph.org/pipermail/speex-dev/attachments/20060724/03c37193/attachment.htm
2007 Dec 12
0
4kbps sounds robotic on TMS320C64
...you test all rates and found 4 kbps to be the only one
problematic? If possible, can you try encoding on one and decoding on
the other, just to see whether the problem is when the encoder or the
decoder? Also, just in case it helps (but I doubt it),
try editing fixed_generic.h and change:
#define SHL32(a,shift) ((a) << (shift))
to
#define SHL32(a,shift) ((spx_int32_t)(a) << (spx_int32_t)(shift))
Cheers,
Jean-Marc
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.xiph.org/pipermail/speex-dev/attachments/20071212/54c8402d/attachment.html
2007 Dec 12
1
4kbps sounds robotic on TMS320C64
Hi,
I'm currently working on the TI DaVinci processor, which has an ARM926 processor and a TMS320C64+ DSP in it. I have been using Speex 6kbps (narrowband, quality=2, complexity=1, perceptual_enh=0) on the DSP C64+ side without any issues; the voice sounds very good for such a low bandwidth requirement. However, recently, I tried out the 4kbps mode (changing quality to 1) on the DSP and it
2011 Sep 01
0
[PATCH 3/5] resample: Add NEON optimized inner_product_single for fixed point
...3fb096e..0e012e9 100644
--- a/libspeex/fixed_generic.h
+++ b/libspeex/fixed_generic.h
@@ -52,6 +52,10 @@
#define SATURATE16(x,a) (((x)>(a) ? (a) : (x)<-(a) ? -(a) : (x)))
#define SATURATE32(x,a) (((x)>(a) ? (a) : (x)<-(a) ? -(a) : (x)))
+#define SATURATE32PSHR(x,shift,a) (((x)>=(SHL32(a,shift))) ? (a) : \
+ (x)<=-(SHL32(a,shift)) ? -(a) : \
+ (PSHR32(x, shift)))
+
#define SHR(a,shift) ((a) >> (shift))
#define SHL(a,shift) ((spx_word32_t)(a) << (shift))
#define PSHR(a,shift) (SHR((a)+((EXTEND32(...
2008 Feb 19
4
Patch for Analog Devices compiler & fixed-point AGC
...);
} else {
for (i=0;i<N+M;i++)
st->echo_noise[i] = 0;
@@ -784,7 +784,7 @@
if (!st->update_prob[i] || st->ps[i] < PSHR32(st->noise[i], NOISE_SHIFT))
st->noise[i] = MAX32(EXTEND32(0),MULT16_32_Q15(beta_1,st->noise[i]) + MULT16_32_Q15(beta,SHL32(st->ps[i],NOISE_SHIFT)));
}
- filterbank_compute_bank32(st->bank, st->noise, st->noise+N);
+ filterbank_compute_bank32(st->bnk, st->noise, st->noise+N);
/* Special case for first frame */
if (st->nb_adapt==1)
@@ -872,13 +872,13 @@
#endif
}
/* Conve...
2005 May 26
0
Speex on TI C6x, Problem with TI C5x Patch
> Nice call. The culprit is SHRL32. This is not used in many places, and in
> most of those, the operand comes from EXTEND32. The only really suspicious
> instances is in lsp.c (lsp_interpolate):
>
> spx_word16_t tmp = DIV32_16(SHL32(1 + subframe,14),nb_subframes);
> (subframe is an int)
> ...
> I see that your changes include adding an EXTEND32 to the line above. I
> made ONLY this change to the 1.1.8 base that I am working from, and the
> problem is gone.
Good. So I guess you are still having your low MIPS...
2010 Jun 15
0
AEC init crashes
...at xiph.org
Subject: [Speex-dev] AEC init crashes
Hello,
I've just caught a strange crash in speex_echo_state_init routine. It
happened only on one WinXP machine, while on others using XP, Vista and
7 everything is fine.
Crash occures in mdf.c line 434: st->spec_average =
DIV32_16(SHL32(EXTEND32(st->frame_size), 15), st->sampling_rate);
Got any ideas or should I provide more information of the OS?
Thanks a lot!
Regards,
Anton A. Shpakovsky
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.xiph.org/pipermail/speex-dev/a...
2006 Dec 01
3
A case indicating VAD bug
Skipped content of type multipart/alternative-------------- next part --------------
A non-text attachment was scrubbed...
Name: output.wav
Type: audio/x-wav
Size: 259244 bytes
Desc: not available
Url : http://lists.xiph.org/pipermail/speex-dev/attachments/20061127/546b3a06/output-0001.wav
-------------- next part --------------
A non-text attachment was scrubbed...
Name: input.inp
Type:
2006 Apr 17
0
Major internal changes, TI DSP build change
...t line 410 in nb_celp.c, because this compiler
will not allow variable declarations in the midst of executable code. I
fixed this by bracketing this code block:
line 410:
{ /* Added */
spx_word16_t *exc16_alias = (spx_word16_t*)st->exc;
--26 more lines, then--
ol_gain = SHL32(EXTEND32(compute_rms16(exc16_alias,
st->frameSize)),SIG_SHIFT);
#ifdef EPIC_48K
}
#endif
} /* Added */
2: The decoder is broken. Running the Male.wav test file, I get all zeros
out for the first 5 seconds, then 8 samples ranging from -2 to 2, and then
all 0001 samples to the e...
2005 May 26
1
Speex on TI C6x, Problem with TI C5x Patch
>> Nice call. The culprit is SHRL32. This is not used in many places, and
>> in
>> most of those, the operand comes from EXTEND32. The only really
>> suspicious
>> instances is in lsp.c (lsp_interpolate):
>>
>> spx_word16_t tmp = DIV32_16(SHL32(1 + subframe,14),nb_subframes);
>> (subframe is an int)
>> ...
>> I see that your changes include adding an EXTEND32 to the line above. I
>> made ONLY this change to the 1.1.8 base that I am working from, and the
>> problem is gone.
>
> Good. So I guess you are...
2010 Feb 05
0
Fwd: Re: Fixed Point on wideband-mode: Single Frame loss on 2000 Hz sine causes "freak off"
...6_t error = ac[0];
for (i = 0; i < p; i++)
lpc[i] = 0;
if (ac[0] == 0)
{
//for (i = 0; i < p; i++)
// lpc[i] = 0;
return 0;
}
for (i = 0; i < p; i++) {
/* Sum up this iteration's reflection coefficient */
spx_word32_t rr = NEG32(SHL32(EXTEND32(ac[i + 1]),13));
for (j = 0; j < i; j++)
rr = SUB32(rr,MULT16_16(lpc[j],ac[i - j]));
#ifdef FIXED_POINT
// stop calculation if error < 30
if ( error <= 30 ) {
return error;
}
//r = DIV32_16(rr+PSHR32(error,1),ADD16(error,10 ));
r = DIV32_16(r...
2006 Apr 19
2
Major internal changes, TI DSP build change
> You found it. The SHL32 (not SHR32) line fixes the problem. It must be
> doing a 16-bit shift, then extending the result (which is reasonable). As
> it happens, that it the same macro which gave us trouble last May
> (25th/26th), when the C55 build was more subtlely broken.
Yes, that's what I finally re...
2016 Jun 17
5
ARM NEON optimization -- celt_fir()
Hi all,
This is Linfeng Zhang from Google. I'll work on ARM NEON optimization in the
next few months.
I'm submitting 2 patches in the following couple of emails, which have the new
created celt_fir_neon().
I revised celt_fir_c() to not pass in argument "mem" in Patch 1. If there are
concerns to this change, please let me know.
Many thanks to your comments.
Linfeng Zhang