Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(82)

Unified Diff: third_party/opus/src/silk/fixed/k2a_FIX.c

Issue 2962373002: [Opus] Update to v1.2.1 (Closed)
Patch Set: Pre-increment instead of post-increment Created 3 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/opus/src/silk/fixed/k2a_FIX.c
diff --git a/third_party/opus/src/silk/fixed/k2a_FIX.c b/third_party/opus/src/silk/fixed/k2a_FIX.c
index 5fee599bcb74305a1d45c41e8795a0ee3f9cb5d9..549f6eadaa29de85bfd4c267c79259c6c114a9d9 100644
--- a/third_party/opus/src/silk/fixed/k2a_FIX.c
+++ b/third_party/opus/src/silk/fixed/k2a_FIX.c
@@ -39,14 +39,15 @@ void silk_k2a(
)
{
opus_int k, n;
- opus_int32 Atmp[ SILK_MAX_ORDER_LPC ];
+ opus_int32 rc, tmp1, tmp2;
for( k = 0; k < order; k++ ) {
- for( n = 0; n < k; n++ ) {
- Atmp[ n ] = A_Q24[ n ];
- }
- for( n = 0; n < k; n++ ) {
- A_Q24[ n ] = silk_SMLAWB( A_Q24[ n ], silk_LSHIFT( Atmp[ k - n - 1 ], 1 ), rc_Q15[ k ] );
+ rc = rc_Q15[ k ];
+ for( n = 0; n < (k + 1) >> 1; n++ ) {
+ tmp1 = A_Q24[ n ];
+ tmp2 = A_Q24[ k - n - 1 ];
+ A_Q24[ n ] = silk_SMLAWB( tmp1, silk_LSHIFT( tmp2, 1 ), rc );
+ A_Q24[ k - n - 1 ] = silk_SMLAWB( tmp2, silk_LSHIFT( tmp1, 1 ), rc );
}
A_Q24[ k ] = -silk_LSHIFT( (opus_int32)rc_Q15[ k ], 9 );
}
« no previous file with comments | « third_party/opus/src/silk/fixed/find_pred_coefs_FIX.c ('k') | third_party/opus/src/silk/fixed/k2a_Q16_FIX.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698