[x265] [PATCH 5 of 6] asm-intrapred8.asm: reduce asm code size

praveen at multicorewareinc.com praveen at multicorewareinc.com
Thu Mar 19 06:03:07 CET 2015


# HG changeset patch
# User Praveen Tiwari <praveen at multicorewareinc.com>
# Date 1426674930 -19800
# Node ID 31378d824cf5ea3ff509b5b9b700ec77f682d875
# Parent  e92e3e58a30c0bc51c3e4bc7f69cdb1308c34a41
asm-intrapred8.asm: reduce asm code size

Introduce macor 'INTRA_PRED_ANG32_STORE' to reduce asm code lines.

diff -r e92e3e58a30c -r 31378d824cf5 source/common/x86/intrapred8.asm
--- a/source/common/x86/intrapred8.asm	Wed Mar 18 15:58:01 2015 +0530
+++ b/source/common/x86/intrapred8.asm	Wed Mar 18 16:05:30 2015 +0530
@@ -11382,57 +11382,29 @@
     INTRA_PRED_ANG32_ALIGNR_STORE 11
     RET
 
-INIT_YMM avx2
-cglobal intra_pred_ang32_26, 3, 4, 1
-    lea    r3, [3 * r1]
-
-    movu    m0,           [r2 + 1]
-
-    movu   [r0],          m0
-    movu   [r0 + r1],     m0
-    movu   [r0 + r1 * 2], m0
-    movu   [r0 + r3],     m0
-
+%macro INTRA_PRED_ANG32_STORE 0
     lea    r0, [r0 + 4 * r1]
     movu   [r0],          m0
     movu   [r0 + r1],     m0
     movu   [r0 + r1 * 2], m0
     movu   [r0 + r3],     m0
-
-    lea    r0, [r0 + 4 * r1]
+%endmacro
+
+INIT_YMM avx2
+cglobal intra_pred_ang32_26, 3, 4, 1
+    lea    r3,            [3 * r1]
+    movu    m0,           [r2 + 1]
     movu   [r0],          m0
     movu   [r0 + r1],     m0
     movu   [r0 + r1 * 2], m0
     movu   [r0 + r3],     m0
 
-    lea    r0, [r0 + 4 * r1]
-    movu   [r0],          m0
-    movu   [r0 + r1],     m0
-    movu   [r0 + r1 * 2], m0
-    movu   [r0 + r3],     m0
-
-    lea    r0, [r0 + 4 * r1]
-    movu   [r0],          m0
-    movu   [r0 + r1],     m0
-    movu   [r0 + r1 * 2], m0
-    movu   [r0 + r3],     m0
-
-    lea    r0, [r0 + 4 * r1]
-    movu   [r0],          m0
-    movu   [r0 + r1],     m0
-    movu   [r0 + r1 * 2], m0
-    movu   [r0 + r3],     m0
-
-    lea    r0, [r0 + 4 * r1]
-    movu   [r0],          m0
-    movu   [r0 + r1],     m0
-    movu   [r0 + r1 * 2], m0
-    movu   [r0 + r3],     m0
-
-    lea    r0, [r0 + 4 * r1]
-    movu   [r0],          m0
-    movu   [r0 + r1],     m0
-    movu   [r0 + r1 * 2], m0
-    movu   [r0 + r3],     m0
-    RET
-
+    INTRA_PRED_ANG32_STORE
+    INTRA_PRED_ANG32_STORE
+    INTRA_PRED_ANG32_STORE
+    INTRA_PRED_ANG32_STORE
+    INTRA_PRED_ANG32_STORE
+    INTRA_PRED_ANG32_STORE
+    INTRA_PRED_ANG32_STORE
+    RET
+


More information about the x265-devel mailing list