Index: webrtc/modules/audio_coding/neteq/expand.cc |
diff --git a/webrtc/modules/audio_coding/neteq/expand.cc b/webrtc/modules/audio_coding/neteq/expand.cc |
index ffe4370e4e61e8766c50ce8efcf22c96bd9723bf..02d6290f2f589cfa26786920afb3f3808ef61665 100644 |
--- a/webrtc/modules/audio_coding/neteq/expand.cc |
+++ b/webrtc/modules/audio_coding/neteq/expand.cc |
@@ -681,10 +681,8 @@ void Expand::AnalyzeSignal(int16_t* random_vector) { |
} else { |
unvoiced_prescale = 0; |
} |
- int32_t unvoiced_energy = WebRtcSpl_DotProductWithScale(unvoiced_vector, |
- unvoiced_vector, |
- 128, |
- unvoiced_prescale); |
+ int32_t unvoiced_energy = WebRtcSpl_DotProductWithScale_64b( |
hlundin-webrtc
2016/12/12 21:40:41
Will you not end up with the same overflow problem
ivoc
2016/12/13 08:43:09
Oops, good catch, I'll change this to int64_t.
kwiberg-webrtc
2016/12/13 08:45:36
I would imagine so. Since all the partial sums are
|
+ unvoiced_vector, unvoiced_vector, 128, unvoiced_prescale); |
// Normalize |unvoiced_energy| to 28 or 29 bits to preserve sqrt() accuracy. |
int16_t unvoiced_scale = WebRtcSpl_NormW32(unvoiced_energy) - 3; |