x86: use PRED4x4/8x8/8x8L/16x16 macros to declare intrapred prototypes.
[ffmpeg.git] / libavcodec / x86 / h264_intrapred_init.c
1 /*
2  * Copyright (c) 2010 Jason Garrett-Glaser
3  *
4  * This file is part of Libav.
5  *
6  * Libav is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU Lesser General Public
8  * License as published by the Free Software Foundation; either
9  * version 2.1 of the License, or (at your option) any later version.
10  *
11  * Libav is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
14  * Lesser General Public License for more details.
15  *
16  * You should have received a copy of the GNU Lesser General Public
17  * License along with Libav; if not, write to the Free Software
18  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
19  */
20
21 #include "libavutil/cpu.h"
22 #include "libavutil/x86/cpu.h"
23 #include "libavcodec/h264pred.h"
24
25 #define PRED4x4(TYPE, DEPTH, OPT) \
26 void ff_pred4x4_ ## TYPE ## _ ## DEPTH ## _ ## OPT (uint8_t *src, const uint8_t *topright, int stride);
27
28 PRED4x4(dc, 10, mmx2)
29 PRED4x4(down_left, 10, sse2)
30 PRED4x4(down_left, 10, avx)
31 PRED4x4(down_right, 10, sse2)
32 PRED4x4(down_right, 10, ssse3)
33 PRED4x4(down_right, 10, avx)
34 PRED4x4(vertical_left, 10, sse2)
35 PRED4x4(vertical_left, 10, avx)
36 PRED4x4(vertical_right, 10, sse2)
37 PRED4x4(vertical_right, 10, ssse3)
38 PRED4x4(vertical_right, 10, avx)
39 PRED4x4(horizontal_up, 10, mmx2)
40 PRED4x4(horizontal_down, 10, sse2)
41 PRED4x4(horizontal_down, 10, ssse3)
42 PRED4x4(horizontal_down, 10, avx)
43
44 #define PRED8x8(TYPE, DEPTH, OPT) \
45 void ff_pred8x8_ ## TYPE ## _ ## DEPTH ## _ ## OPT (uint8_t *src, int stride);
46
47 PRED8x8(dc, 10, mmx2)
48 PRED8x8(dc, 10, sse2)
49 PRED8x8(top_dc, 10, sse2)
50 PRED8x8(plane, 10, sse2)
51 PRED8x8(vertical, 10, sse2)
52 PRED8x8(horizontal, 10, sse2)
53
54 #define PRED8x8L(TYPE, DEPTH, OPT)\
55 void ff_pred8x8l_ ## TYPE ## _ ## DEPTH ## _ ## OPT (uint8_t *src, int has_topleft, int has_topright, int stride);
56
57 PRED8x8L(dc, 10, sse2)
58 PRED8x8L(dc, 10, avx)
59 PRED8x8L(128_dc, 10, mmx2)
60 PRED8x8L(128_dc, 10, sse2)
61 PRED8x8L(top_dc, 10, sse2)
62 PRED8x8L(top_dc, 10, avx)
63 PRED8x8L(vertical, 10, sse2)
64 PRED8x8L(vertical, 10, avx)
65 PRED8x8L(horizontal, 10, sse2)
66 PRED8x8L(horizontal, 10, ssse3)
67 PRED8x8L(horizontal, 10, avx)
68 PRED8x8L(down_left, 10, sse2)
69 PRED8x8L(down_left, 10, ssse3)
70 PRED8x8L(down_left, 10, avx)
71 PRED8x8L(down_right, 10, sse2)
72 PRED8x8L(down_right, 10, ssse3)
73 PRED8x8L(down_right, 10, avx)
74 PRED8x8L(vertical_right, 10, sse2)
75 PRED8x8L(vertical_right, 10, ssse3)
76 PRED8x8L(vertical_right, 10, avx)
77 PRED8x8L(horizontal_up, 10, sse2)
78 PRED8x8L(horizontal_up, 10, ssse3)
79 PRED8x8L(horizontal_up, 10, avx)
80
81 #define PRED16x16(TYPE, DEPTH, OPT)\
82 void ff_pred16x16_ ## TYPE ## _ ## DEPTH ## _ ## OPT (uint8_t *src, int stride);
83
84 PRED16x16(dc, 10, mmx2)
85 PRED16x16(dc, 10, sse2)
86 PRED16x16(top_dc, 10, mmx2)
87 PRED16x16(top_dc, 10, sse2)
88 PRED16x16(128_dc, 10, mmx2)
89 PRED16x16(128_dc, 10, sse2)
90 PRED16x16(left_dc, 10, mmx2)
91 PRED16x16(left_dc, 10, sse2)
92 PRED16x16(vertical, 10, mmx2)
93 PRED16x16(vertical, 10, sse2)
94 PRED16x16(horizontal, 10, mmx2)
95 PRED16x16(horizontal, 10, sse2)
96
97 /* 8-bit versions */
98 PRED16x16(vertical, 8, mmx)
99 PRED16x16(vertical, 8, sse)
100 PRED16x16(horizontal, 8, mmx)
101 PRED16x16(horizontal, 8, mmx2)
102 PRED16x16(horizontal, 8, ssse3)
103 PRED16x16(dc, 8, mmx2)
104 PRED16x16(dc, 8, sse2)
105 PRED16x16(dc, 8, ssse3)
106 PRED16x16(plane_h264, 8, mmx)
107 PRED16x16(plane_h264, 8, mmx2)
108 PRED16x16(plane_h264, 8, sse2)
109 PRED16x16(plane_h264, 8, ssse3)
110 PRED16x16(plane_rv40, 8, mmx)
111 PRED16x16(plane_rv40, 8, mmx2)
112 PRED16x16(plane_rv40, 8, sse2)
113 PRED16x16(plane_rv40, 8, ssse3)
114 PRED16x16(plane_svq3, 8, mmx)
115 PRED16x16(plane_svq3, 8, mmx2)
116 PRED16x16(plane_svq3, 8, sse2)
117 PRED16x16(plane_svq3, 8, ssse3)
118 PRED16x16(tm_vp8, 8, mmx)
119 PRED16x16(tm_vp8, 8, mmx2)
120 PRED16x16(tm_vp8, 8, sse2)
121
122 PRED8x8(top_dc, 8, mmxext)
123 PRED8x8(dc_rv40, 8, mmxext)
124 PRED8x8(dc, 8, mmxext)
125 PRED8x8(vertical, 8, mmx)
126 PRED8x8(horizontal, 8, mmx)
127 PRED8x8(horizontal, 8, mmx2)
128 PRED8x8(horizontal, 8, ssse3)
129 PRED8x8(plane, 8, mmx)
130 PRED8x8(plane, 8, mmx2)
131 PRED8x8(plane, 8, sse2)
132 PRED8x8(plane, 8, ssse3)
133 PRED8x8(tm_vp8, 8, mmx)
134 PRED8x8(tm_vp8, 8, mmx2)
135 PRED8x8(tm_vp8, 8, sse2)
136 PRED8x8(tm_vp8, 8, ssse3)
137
138 PRED8x8L(top_dc, 8, mmxext)
139 PRED8x8L(top_dc, 8, ssse3)
140 PRED8x8L(dc, 8, mmxext)
141 PRED8x8L(dc, 8, ssse3)
142 PRED8x8L(horizontal, 8, mmxext)
143 PRED8x8L(horizontal, 8, ssse3)
144 PRED8x8L(vertical, 8, mmxext)
145 PRED8x8L(vertical, 8, ssse3)
146 PRED8x8L(down_left, 8, mmxext)
147 PRED8x8L(down_left, 8, sse2)
148 PRED8x8L(down_left, 8, ssse3)
149 PRED8x8L(down_right, 8, mmxext)
150 PRED8x8L(down_right, 8, sse2)
151 PRED8x8L(down_right, 8, ssse3)
152 PRED8x8L(vertical_right, 8, mmxext)
153 PRED8x8L(vertical_right, 8, sse2)
154 PRED8x8L(vertical_right, 8, ssse3)
155 PRED8x8L(vertical_left, 8, sse2)
156 PRED8x8L(vertical_left, 8, ssse3)
157 PRED8x8L(horizontal_up, 8, mmxext)
158 PRED8x8L(horizontal_up, 8, ssse3)
159 PRED8x8L(horizontal_down, 8, mmxext)
160 PRED8x8L(horizontal_down, 8, sse2)
161 PRED8x8L(horizontal_down, 8, ssse3)
162
163 PRED4x4(dc, 8, mmxext)
164 PRED4x4(down_left, 8, mmxext)
165 PRED4x4(down_right, 8, mmxext)
166 PRED4x4(vertical_left, 8, mmxext)
167 PRED4x4(vertical_right, 8, mmxext)
168 PRED4x4(horizontal_up, 8, mmxext)
169 PRED4x4(horizontal_down, 8, mmxext)
170 PRED4x4(tm_vp8, 8, mmx)
171 PRED4x4(tm_vp8, 8, mmx2)
172 PRED4x4(tm_vp8, 8, ssse3)
173 PRED4x4(vertical_vp8, 8, mmxext)
174
175 void ff_h264_pred_init_x86(H264PredContext *h, int codec_id, const int bit_depth, const int chroma_format_idc)
176 {
177     int mm_flags = av_get_cpu_flags();
178
179     if (bit_depth == 8) {
180         if (EXTERNAL_MMX(mm_flags)) {
181             h->pred16x16[VERT_PRED8x8         ] = ff_pred16x16_vertical_8_mmx;
182             h->pred16x16[HOR_PRED8x8          ] = ff_pred16x16_horizontal_8_mmx;
183             if (chroma_format_idc == 1) {
184                 h->pred8x8  [VERT_PRED8x8     ] = ff_pred8x8_vertical_8_mmx;
185                 h->pred8x8  [HOR_PRED8x8      ] = ff_pred8x8_horizontal_8_mmx;
186             }
187             if (codec_id == AV_CODEC_ID_VP8) {
188                 h->pred16x16[PLANE_PRED8x8    ] = ff_pred16x16_tm_vp8_8_mmx;
189                 h->pred8x8  [PLANE_PRED8x8    ] = ff_pred8x8_tm_vp8_8_mmx;
190                 h->pred4x4  [TM_VP8_PRED      ] = ff_pred4x4_tm_vp8_8_mmx;
191             } else {
192                 if (chroma_format_idc == 1)
193                     h->pred8x8  [PLANE_PRED8x8] = ff_pred8x8_plane_8_mmx;
194                 if (codec_id == AV_CODEC_ID_SVQ3) {
195                     if (mm_flags & AV_CPU_FLAG_CMOV)
196                         h->pred16x16[PLANE_PRED8x8] = ff_pred16x16_plane_svq3_8_mmx;
197                 } else if (codec_id == AV_CODEC_ID_RV40) {
198                     h->pred16x16[PLANE_PRED8x8] = ff_pred16x16_plane_rv40_8_mmx;
199                 } else {
200                     h->pred16x16[PLANE_PRED8x8] = ff_pred16x16_plane_h264_8_mmx;
201                 }
202             }
203         }
204
205         if (EXTERNAL_MMXEXT(mm_flags)) {
206             h->pred16x16[HOR_PRED8x8            ] = ff_pred16x16_horizontal_8_mmx2;
207             h->pred16x16[DC_PRED8x8             ] = ff_pred16x16_dc_8_mmx2;
208             if (chroma_format_idc == 1)
209                 h->pred8x8[HOR_PRED8x8          ] = ff_pred8x8_horizontal_8_mmx2;
210             h->pred8x8l [TOP_DC_PRED            ] = ff_pred8x8l_top_dc_8_mmxext;
211             h->pred8x8l [DC_PRED                ] = ff_pred8x8l_dc_8_mmxext;
212             h->pred8x8l [HOR_PRED               ] = ff_pred8x8l_horizontal_8_mmxext;
213             h->pred8x8l [VERT_PRED              ] = ff_pred8x8l_vertical_8_mmxext;
214             h->pred8x8l [DIAG_DOWN_RIGHT_PRED   ] = ff_pred8x8l_down_right_8_mmxext;
215             h->pred8x8l [VERT_RIGHT_PRED        ] = ff_pred8x8l_vertical_right_8_mmxext;
216             h->pred8x8l [HOR_UP_PRED            ] = ff_pred8x8l_horizontal_up_8_mmxext;
217             h->pred8x8l [DIAG_DOWN_LEFT_PRED    ] = ff_pred8x8l_down_left_8_mmxext;
218             h->pred8x8l [HOR_DOWN_PRED          ] = ff_pred8x8l_horizontal_down_8_mmxext;
219             h->pred4x4  [DIAG_DOWN_RIGHT_PRED   ] = ff_pred4x4_down_right_8_mmxext;
220             h->pred4x4  [VERT_RIGHT_PRED        ] = ff_pred4x4_vertical_right_8_mmxext;
221             h->pred4x4  [HOR_DOWN_PRED          ] = ff_pred4x4_horizontal_down_8_mmxext;
222             h->pred4x4  [DC_PRED                ] = ff_pred4x4_dc_8_mmxext;
223             if (codec_id == AV_CODEC_ID_VP8 || codec_id == AV_CODEC_ID_H264) {
224                 h->pred4x4  [DIAG_DOWN_LEFT_PRED] = ff_pred4x4_down_left_8_mmxext;
225             }
226             if (codec_id == AV_CODEC_ID_SVQ3 || codec_id == AV_CODEC_ID_H264) {
227                 h->pred4x4  [VERT_LEFT_PRED     ] = ff_pred4x4_vertical_left_8_mmxext;
228             }
229             if (codec_id != AV_CODEC_ID_RV40) {
230                 h->pred4x4  [HOR_UP_PRED        ] = ff_pred4x4_horizontal_up_8_mmxext;
231             }
232             if (codec_id == AV_CODEC_ID_SVQ3 || codec_id == AV_CODEC_ID_H264) {
233                 if (chroma_format_idc == 1) {
234                     h->pred8x8[TOP_DC_PRED8x8   ] = ff_pred8x8_top_dc_8_mmxext;
235                     h->pred8x8[DC_PRED8x8       ] = ff_pred8x8_dc_8_mmxext;
236                 }
237             }
238             if (codec_id == AV_CODEC_ID_VP8) {
239                 h->pred16x16[PLANE_PRED8x8      ] = ff_pred16x16_tm_vp8_8_mmx2;
240                 h->pred8x8  [DC_PRED8x8         ] = ff_pred8x8_dc_rv40_8_mmxext;
241                 h->pred8x8  [PLANE_PRED8x8      ] = ff_pred8x8_tm_vp8_8_mmx2;
242                 h->pred4x4  [TM_VP8_PRED        ] = ff_pred4x4_tm_vp8_8_mmx2;
243                 h->pred4x4  [VERT_PRED          ] = ff_pred4x4_vertical_vp8_8_mmxext;
244             } else {
245                 if (chroma_format_idc == 1)
246                     h->pred8x8  [PLANE_PRED8x8] = ff_pred8x8_plane_8_mmx2;
247                 if (codec_id == AV_CODEC_ID_SVQ3) {
248                     h->pred16x16[PLANE_PRED8x8  ] = ff_pred16x16_plane_svq3_8_mmx2;
249                 } else if (codec_id == AV_CODEC_ID_RV40) {
250                     h->pred16x16[PLANE_PRED8x8  ] = ff_pred16x16_plane_rv40_8_mmx2;
251                 } else {
252                     h->pred16x16[PLANE_PRED8x8  ] = ff_pred16x16_plane_h264_8_mmx2;
253                 }
254             }
255         }
256
257         if (EXTERNAL_SSE(mm_flags)) {
258             h->pred16x16[VERT_PRED8x8] = ff_pred16x16_vertical_8_sse;
259         }
260
261         if (EXTERNAL_SSE2(mm_flags)) {
262             h->pred16x16[DC_PRED8x8           ] = ff_pred16x16_dc_8_sse2;
263             h->pred8x8l [DIAG_DOWN_LEFT_PRED  ] = ff_pred8x8l_down_left_8_sse2;
264             h->pred8x8l [DIAG_DOWN_RIGHT_PRED ] = ff_pred8x8l_down_right_8_sse2;
265             h->pred8x8l [VERT_RIGHT_PRED      ] = ff_pred8x8l_vertical_right_8_sse2;
266             h->pred8x8l [VERT_LEFT_PRED       ] = ff_pred8x8l_vertical_left_8_sse2;
267             h->pred8x8l [HOR_DOWN_PRED        ] = ff_pred8x8l_horizontal_down_8_sse2;
268             if (codec_id == AV_CODEC_ID_VP8) {
269                 h->pred16x16[PLANE_PRED8x8    ] = ff_pred16x16_tm_vp8_8_sse2;
270                 h->pred8x8  [PLANE_PRED8x8    ] = ff_pred8x8_tm_vp8_8_sse2;
271             } else {
272                 if (chroma_format_idc == 1)
273                     h->pred8x8  [PLANE_PRED8x8] = ff_pred8x8_plane_8_sse2;
274                 if (codec_id == AV_CODEC_ID_SVQ3) {
275                     h->pred16x16[PLANE_PRED8x8] = ff_pred16x16_plane_svq3_8_sse2;
276                 } else if (codec_id == AV_CODEC_ID_RV40) {
277                     h->pred16x16[PLANE_PRED8x8] = ff_pred16x16_plane_rv40_8_sse2;
278                 } else {
279                     h->pred16x16[PLANE_PRED8x8] = ff_pred16x16_plane_h264_8_sse2;
280                 }
281             }
282         }
283
284         if (EXTERNAL_SSSE3(mm_flags)) {
285             h->pred16x16[HOR_PRED8x8          ] = ff_pred16x16_horizontal_8_ssse3;
286             h->pred16x16[DC_PRED8x8           ] = ff_pred16x16_dc_8_ssse3;
287             if (chroma_format_idc == 1)
288                 h->pred8x8  [HOR_PRED8x8      ] = ff_pred8x8_horizontal_8_ssse3;
289             h->pred8x8l [TOP_DC_PRED          ] = ff_pred8x8l_top_dc_8_ssse3;
290             h->pred8x8l [DC_PRED              ] = ff_pred8x8l_dc_8_ssse3;
291             h->pred8x8l [HOR_PRED             ] = ff_pred8x8l_horizontal_8_ssse3;
292             h->pred8x8l [VERT_PRED            ] = ff_pred8x8l_vertical_8_ssse3;
293             h->pred8x8l [DIAG_DOWN_LEFT_PRED  ] = ff_pred8x8l_down_left_8_ssse3;
294             h->pred8x8l [DIAG_DOWN_RIGHT_PRED ] = ff_pred8x8l_down_right_8_ssse3;
295             h->pred8x8l [VERT_RIGHT_PRED      ] = ff_pred8x8l_vertical_right_8_ssse3;
296             h->pred8x8l [VERT_LEFT_PRED       ] = ff_pred8x8l_vertical_left_8_ssse3;
297             h->pred8x8l [HOR_UP_PRED          ] = ff_pred8x8l_horizontal_up_8_ssse3;
298             h->pred8x8l [HOR_DOWN_PRED        ] = ff_pred8x8l_horizontal_down_8_ssse3;
299             if (codec_id == AV_CODEC_ID_VP8) {
300                 h->pred8x8  [PLANE_PRED8x8    ] = ff_pred8x8_tm_vp8_8_ssse3;
301                 h->pred4x4  [TM_VP8_PRED      ] = ff_pred4x4_tm_vp8_8_ssse3;
302             } else {
303                 if (chroma_format_idc == 1)
304                     h->pred8x8  [PLANE_PRED8x8] = ff_pred8x8_plane_8_ssse3;
305                 if (codec_id == AV_CODEC_ID_SVQ3) {
306                     h->pred16x16[PLANE_PRED8x8] = ff_pred16x16_plane_svq3_8_ssse3;
307                 } else if (codec_id == AV_CODEC_ID_RV40) {
308                     h->pred16x16[PLANE_PRED8x8] = ff_pred16x16_plane_rv40_8_ssse3;
309                 } else {
310                     h->pred16x16[PLANE_PRED8x8] = ff_pred16x16_plane_h264_8_ssse3;
311                 }
312             }
313         }
314     } else if (bit_depth == 10) {
315         if (EXTERNAL_MMXEXT(mm_flags)) {
316             h->pred4x4[DC_PRED             ] = ff_pred4x4_dc_10_mmx2;
317             h->pred4x4[HOR_UP_PRED         ] = ff_pred4x4_horizontal_up_10_mmx2;
318
319             if (chroma_format_idc == 1)
320                 h->pred8x8[DC_PRED8x8      ] = ff_pred8x8_dc_10_mmx2;
321
322             h->pred8x8l[DC_128_PRED        ] = ff_pred8x8l_128_dc_10_mmx2;
323
324             h->pred16x16[DC_PRED8x8        ] = ff_pred16x16_dc_10_mmx2;
325             h->pred16x16[TOP_DC_PRED8x8    ] = ff_pred16x16_top_dc_10_mmx2;
326             h->pred16x16[DC_128_PRED8x8    ] = ff_pred16x16_128_dc_10_mmx2;
327             h->pred16x16[LEFT_DC_PRED8x8   ] = ff_pred16x16_left_dc_10_mmx2;
328             h->pred16x16[VERT_PRED8x8      ] = ff_pred16x16_vertical_10_mmx2;
329             h->pred16x16[HOR_PRED8x8       ] = ff_pred16x16_horizontal_10_mmx2;
330         }
331         if (EXTERNAL_SSE2(mm_flags)) {
332             h->pred4x4[DIAG_DOWN_LEFT_PRED ] = ff_pred4x4_down_left_10_sse2;
333             h->pred4x4[DIAG_DOWN_RIGHT_PRED] = ff_pred4x4_down_right_10_sse2;
334             h->pred4x4[VERT_LEFT_PRED      ] = ff_pred4x4_vertical_left_10_sse2;
335             h->pred4x4[VERT_RIGHT_PRED     ] = ff_pred4x4_vertical_right_10_sse2;
336             h->pred4x4[HOR_DOWN_PRED       ] = ff_pred4x4_horizontal_down_10_sse2;
337
338             if (chroma_format_idc == 1) {
339                 h->pred8x8[DC_PRED8x8      ] = ff_pred8x8_dc_10_sse2;
340                 h->pred8x8[TOP_DC_PRED8x8  ] = ff_pred8x8_top_dc_10_sse2;
341                 h->pred8x8[PLANE_PRED8x8   ] = ff_pred8x8_plane_10_sse2;
342                 h->pred8x8[VERT_PRED8x8    ] = ff_pred8x8_vertical_10_sse2;
343                 h->pred8x8[HOR_PRED8x8     ] = ff_pred8x8_horizontal_10_sse2;
344             }
345
346             h->pred8x8l[VERT_PRED           ] = ff_pred8x8l_vertical_10_sse2;
347             h->pred8x8l[HOR_PRED            ] = ff_pred8x8l_horizontal_10_sse2;
348             h->pred8x8l[DC_PRED             ] = ff_pred8x8l_dc_10_sse2;
349             h->pred8x8l[DC_128_PRED         ] = ff_pred8x8l_128_dc_10_sse2;
350             h->pred8x8l[TOP_DC_PRED         ] = ff_pred8x8l_top_dc_10_sse2;
351             h->pred8x8l[DIAG_DOWN_LEFT_PRED ] = ff_pred8x8l_down_left_10_sse2;
352             h->pred8x8l[DIAG_DOWN_RIGHT_PRED] = ff_pred8x8l_down_right_10_sse2;
353             h->pred8x8l[VERT_RIGHT_PRED     ] = ff_pred8x8l_vertical_right_10_sse2;
354             h->pred8x8l[HOR_UP_PRED         ] = ff_pred8x8l_horizontal_up_10_sse2;
355
356             h->pred16x16[DC_PRED8x8        ] = ff_pred16x16_dc_10_sse2;
357             h->pred16x16[TOP_DC_PRED8x8    ] = ff_pred16x16_top_dc_10_sse2;
358             h->pred16x16[DC_128_PRED8x8    ] = ff_pred16x16_128_dc_10_sse2;
359             h->pred16x16[LEFT_DC_PRED8x8   ] = ff_pred16x16_left_dc_10_sse2;
360             h->pred16x16[VERT_PRED8x8      ] = ff_pred16x16_vertical_10_sse2;
361             h->pred16x16[HOR_PRED8x8       ] = ff_pred16x16_horizontal_10_sse2;
362         }
363         if (EXTERNAL_SSSE3(mm_flags)) {
364             h->pred4x4[DIAG_DOWN_RIGHT_PRED] = ff_pred4x4_down_right_10_ssse3;
365             h->pred4x4[VERT_RIGHT_PRED     ] = ff_pred4x4_vertical_right_10_ssse3;
366             h->pred4x4[HOR_DOWN_PRED       ] = ff_pred4x4_horizontal_down_10_ssse3;
367
368             h->pred8x8l[HOR_PRED            ] = ff_pred8x8l_horizontal_10_ssse3;
369             h->pred8x8l[DIAG_DOWN_LEFT_PRED ] = ff_pred8x8l_down_left_10_ssse3;
370             h->pred8x8l[DIAG_DOWN_RIGHT_PRED] = ff_pred8x8l_down_right_10_ssse3;
371             h->pred8x8l[VERT_RIGHT_PRED     ] = ff_pred8x8l_vertical_right_10_ssse3;
372             h->pred8x8l[HOR_UP_PRED         ] = ff_pred8x8l_horizontal_up_10_ssse3;
373         }
374         if (EXTERNAL_AVX(mm_flags)) {
375             h->pred4x4[DIAG_DOWN_LEFT_PRED ] = ff_pred4x4_down_left_10_avx;
376             h->pred4x4[DIAG_DOWN_RIGHT_PRED] = ff_pred4x4_down_right_10_avx;
377             h->pred4x4[VERT_LEFT_PRED      ] = ff_pred4x4_vertical_left_10_avx;
378             h->pred4x4[VERT_RIGHT_PRED     ] = ff_pred4x4_vertical_right_10_avx;
379             h->pred4x4[HOR_DOWN_PRED       ] = ff_pred4x4_horizontal_down_10_avx;
380
381             h->pred8x8l[VERT_PRED           ] = ff_pred8x8l_vertical_10_avx;
382             h->pred8x8l[HOR_PRED            ] = ff_pred8x8l_horizontal_10_avx;
383             h->pred8x8l[DC_PRED             ] = ff_pred8x8l_dc_10_avx;
384             h->pred8x8l[TOP_DC_PRED         ] = ff_pred8x8l_top_dc_10_avx;
385             h->pred8x8l[DIAG_DOWN_RIGHT_PRED] = ff_pred8x8l_down_right_10_avx;
386             h->pred8x8l[DIAG_DOWN_LEFT_PRED ] = ff_pred8x8l_down_left_10_avx;
387             h->pred8x8l[VERT_RIGHT_PRED     ] = ff_pred8x8l_vertical_right_10_avx;
388             h->pred8x8l[HOR_UP_PRED         ] = ff_pred8x8l_horizontal_up_10_avx;
389         }
390     }
391 }