[x265] [PATCH 2 of 2] Adding asm function declarations and initializations for chroma vss filter functions

nabajit at multicorewareinc.com nabajit at multicorewareinc.com
Fri Nov 15 12:41:08 CET 2013


# HG changeset patch
# User Nabajit Deka
# Date 1384515584 -19800
#      Fri Nov 15 17:09:44 2013 +0530
# Node ID 07329593c7024c8fc20127ebe1144dab26b1008c
# Parent  9842bb0aab4c3b3a5b241d77cf6436d8bd7e717f
Adding asm function declarations and initializations for chroma vss filter functions

diff -r 9842bb0aab4c -r 07329593c702 source/common/x86/asm-primitives.cpp
--- a/source/common/x86/asm-primitives.cpp	Fri Nov 15 17:06:24 2013 +0530
+++ b/source/common/x86/asm-primitives.cpp	Fri Nov 15 17:09:44 2013 +0530
@@ -146,6 +146,9 @@
 #define SETUP_CHROMA_SP_FUNC_DEF(W, H, cpu) \
     p.chroma_vsp[CHROMA_ ## W ## x ## H] = x265_interp_4tap_vert_sp_ ## W ## x ## H ## cpu;
 
+#define SETUP_CHROMA_SS_FUNC_DEF(W, H, cpu) \
+    p.chroma_vss[CHROMA_ ## W ## x ## H] = x265_interp_4tap_vert_ss_ ## W ## x ## H ## cpu;
+
 #define SETUP_CHROMA_BLOCKCOPY_FUNC_DEF(W, H, cpu) \
     p.chroma_copy_pp[CHROMA_ ## W ## x ## H] = x265_blockcopy_pp_ ## W ## x ## H ## cpu;
 
@@ -198,6 +201,32 @@
     SETUP_CHROMA_SP_FUNC_DEF(32, 8, cpu); \
     SETUP_CHROMA_SP_FUNC_DEF(8, 32, cpu);
 
+#define CHROMA_SS_FILTERS(cpu) \
+    SETUP_CHROMA_SS_FUNC_DEF(4, 4, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(4, 2, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(2, 4, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(8, 8, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(8, 4, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(4, 8, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(8, 6, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(6, 8, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(8, 2, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(2, 8, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(16, 16, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(16, 8, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(8, 16, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(16, 12, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(12, 16, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(16, 4, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(4, 16, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(32, 32, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(32, 16, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(16, 32, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(32, 24, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(24, 32, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(32, 8, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(8, 32, cpu);
+
 #define CHROMA_BLOCKCOPY(cpu) \
     SETUP_CHROMA_BLOCKCOPY_FUNC_DEF(4, 4, cpu); \
     SETUP_CHROMA_BLOCKCOPY_FUNC_DEF(4, 2, cpu); \
@@ -404,6 +433,8 @@
         CHROMA_BLOCKCOPY(_sse2);
         LUMA_BLOCKCOPY(_sse2);
 
+        CHROMA_SS_FILTERS(_sse2);
+
         // This function pointer initialization is temporary will be removed
         // later with macro definitions.  It is used to avoid linker errors
         // until all partitions are coded and commit smaller patches, easier to
diff -r 9842bb0aab4c -r 07329593c702 source/common/x86/ipfilter8.h
--- a/source/common/x86/ipfilter8.h	Fri Nov 15 17:06:24 2013 +0530
+++ b/source/common/x86/ipfilter8.h	Fri Nov 15 17:09:44 2013 +0530
@@ -145,9 +145,39 @@
     SETUP_CHROMA_SP_FUNC_DEF(32, 8, cpu); \
     SETUP_CHROMA_SP_FUNC_DEF(8, 32, cpu);
 
+  #define SETUP_CHROMA_SS_FUNC_DEF(W, H, cpu) \
+    void x265_interp_4tap_vert_ss_ ## W ## x ## H ## cpu(int16_t * src, intptr_t srcStride, int16_t * dst, intptr_t dstStride, int coeffIdx);
+
+#define CHROMA_SS_FILTERS(cpu) \
+    SETUP_CHROMA_SS_FUNC_DEF(4, 4, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(4, 2, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(2, 4, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(8, 8, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(8, 4, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(4, 8, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(8, 6, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(6, 8, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(8, 2, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(2, 8, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(16, 16, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(16, 8, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(8, 16, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(16, 12, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(12, 16, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(16, 4, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(4, 16, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(32, 32, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(32, 16, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(16, 32, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(32, 24, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(24, 32, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(32, 8, cpu); \
+    SETUP_CHROMA_SS_FUNC_DEF(8, 32, cpu)
+
 
 CHROMA_FILTERS(_sse4);
 CHROMA_SP_FILTERS(_ssse3);
+CHROMA_SS_FILTERS(_sse2);
 LUMA_FILTERS(_sse4);
 LUMA_SP_FILTERS(_ssse3);
 
@@ -161,10 +191,12 @@
 
 #undef SETUP_CHROMA_FUNC_DEF
 #undef SETUP_CHROMA_SP_FUNC_DEF
+#undef SETUP_CHROMA_SS_FUNC_DEF
 #undef SETUP_LUMA_FUNC_DEF
 #undef SETUP_LUMA_SP_FUNC_DEF
 #undef CHROMA_FILTERS
 #undef CHROMA_SP_FILTERS
+#undef CHROMA_SS_FILTERS
 #undef LUMA_FILTERS
 #undef LUMA_SP_FILTERS
 


More information about the x265-devel mailing list