[x265] [PATCH] idct32_c: C code optimization

praveen at multicorewareinc.com praveen at multicorewareinc.com
Fri Nov 21 07:37:33 CET 2014


# HG changeset patch
# User Praveen Tiwari
# Date 1416551634 -19800
# Node ID c5bbb66412a47835cc8b0352169f2254cd929fce
# Parent  2e897adea4fb2f0d9c29e5fe29883d5a2baec818
idct32_c: C code optimization

diff -r 2e897adea4fb -r c5bbb66412a4 source/common/dct.cpp
--- a/source/common/dct.cpp	Fri Nov 21 11:31:27 2014 +0530
+++ b/source/common/dct.cpp	Fri Nov 21 12:03:54 2014 +0530
@@ -599,18 +599,7 @@
     ALIGN_VAR_32(int16_t, coef[32 * 32]);
     ALIGN_VAR_32(int16_t, block[32 * 32]);
 
-#define N (32)
-    for (int i = 0; i < N; i++)
-    {
-        for (int j = 0; j < N; j++)
-        {
-            block[i * N + j] = (int16_t)src[i * N + j];
-        }
-    }
-
-#undef N
-
-    partialButterflyInverse32(block, coef, shift_1st, 32);
+    partialButterflyInverse32(src, coef, shift_1st, 32);
     partialButterflyInverse32(coef, block, shift_2nd, 32);
 
     for (int i = 0; i < 32; i++)


More information about the x265-devel mailing list