h264_intrapred_init.c 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410
  1. /*
  2. * Copyright (c) 2010 Fiona Glaser <fiona@x264.com>
  3. *
  4. * This file is part of FFmpeg.
  5. *
  6. * FFmpeg 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. * FFmpeg 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 FFmpeg; if not, write to the Free Software
  18. * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  19. */
  20. #include "libavutil/attributes.h"
  21. #include "libavutil/cpu.h"
  22. #include "libavutil/x86/cpu.h"
  23. #include "libavcodec/avcodec.h"
  24. #include "libavcodec/h264pred.h"
  25. #define PRED4x4(TYPE, DEPTH, OPT) \
  26. void ff_pred4x4_ ## TYPE ## _ ## DEPTH ## _ ## OPT (uint8_t *src, \
  27. const uint8_t *topright, \
  28. ptrdiff_t stride);
  29. PRED4x4(dc, 10, mmxext)
  30. PRED4x4(down_left, 10, sse2)
  31. PRED4x4(down_left, 10, avx)
  32. PRED4x4(down_right, 10, sse2)
  33. PRED4x4(down_right, 10, ssse3)
  34. PRED4x4(down_right, 10, avx)
  35. PRED4x4(vertical_left, 10, sse2)
  36. PRED4x4(vertical_left, 10, avx)
  37. PRED4x4(vertical_right, 10, sse2)
  38. PRED4x4(vertical_right, 10, ssse3)
  39. PRED4x4(vertical_right, 10, avx)
  40. PRED4x4(horizontal_up, 10, mmxext)
  41. PRED4x4(horizontal_down, 10, sse2)
  42. PRED4x4(horizontal_down, 10, ssse3)
  43. PRED4x4(horizontal_down, 10, avx)
  44. #define PRED8x8(TYPE, DEPTH, OPT) \
  45. void ff_pred8x8_ ## TYPE ## _ ## DEPTH ## _ ## OPT (uint8_t *src, \
  46. ptrdiff_t stride);
  47. PRED8x8(dc, 10, mmxext)
  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. #define PRED8x8L(TYPE, DEPTH, OPT)\
  54. void ff_pred8x8l_ ## TYPE ## _ ## DEPTH ## _ ## OPT (uint8_t *src, \
  55. int has_topleft, \
  56. int has_topright, \
  57. ptrdiff_t stride);
  58. PRED8x8L(dc, 10, sse2)
  59. PRED8x8L(dc, 10, avx)
  60. PRED8x8L(128_dc, 10, mmxext)
  61. PRED8x8L(128_dc, 10, sse2)
  62. PRED8x8L(top_dc, 10, sse2)
  63. PRED8x8L(top_dc, 10, avx)
  64. PRED8x8L(vertical, 10, sse2)
  65. PRED8x8L(vertical, 10, avx)
  66. PRED8x8L(horizontal, 10, sse2)
  67. PRED8x8L(horizontal, 10, ssse3)
  68. PRED8x8L(horizontal, 10, avx)
  69. PRED8x8L(down_left, 10, sse2)
  70. PRED8x8L(down_left, 10, ssse3)
  71. PRED8x8L(down_left, 10, avx)
  72. PRED8x8L(down_right, 10, sse2)
  73. PRED8x8L(down_right, 10, ssse3)
  74. PRED8x8L(down_right, 10, avx)
  75. PRED8x8L(vertical_right, 10, sse2)
  76. PRED8x8L(vertical_right, 10, ssse3)
  77. PRED8x8L(vertical_right, 10, avx)
  78. PRED8x8L(horizontal_up, 10, sse2)
  79. PRED8x8L(horizontal_up, 10, ssse3)
  80. PRED8x8L(horizontal_up, 10, avx)
  81. #define PRED16x16(TYPE, DEPTH, OPT)\
  82. void ff_pred16x16_ ## TYPE ## _ ## DEPTH ## _ ## OPT (uint8_t *src, \
  83. ptrdiff_t stride);
  84. PRED16x16(dc, 10, mmxext)
  85. PRED16x16(dc, 10, sse2)
  86. PRED16x16(top_dc, 10, mmxext)
  87. PRED16x16(top_dc, 10, sse2)
  88. PRED16x16(128_dc, 10, mmxext)
  89. PRED16x16(128_dc, 10, sse2)
  90. PRED16x16(left_dc, 10, mmxext)
  91. PRED16x16(left_dc, 10, sse2)
  92. PRED16x16(vertical, 10, mmxext)
  93. PRED16x16(vertical, 10, sse2)
  94. PRED16x16(horizontal, 10, mmxext)
  95. PRED16x16(horizontal, 10, sse2)
  96. /* 8-bit versions */
  97. PRED16x16(vertical, 8, mmx)
  98. PRED16x16(vertical, 8, sse)
  99. PRED16x16(horizontal, 8, mmx)
  100. PRED16x16(horizontal, 8, mmxext)
  101. PRED16x16(horizontal, 8, ssse3)
  102. PRED16x16(dc, 8, mmxext)
  103. PRED16x16(dc, 8, sse2)
  104. PRED16x16(dc, 8, ssse3)
  105. PRED16x16(plane_h264, 8, mmx)
  106. PRED16x16(plane_h264, 8, mmxext)
  107. PRED16x16(plane_h264, 8, sse2)
  108. PRED16x16(plane_h264, 8, ssse3)
  109. PRED16x16(plane_rv40, 8, mmx)
  110. PRED16x16(plane_rv40, 8, mmxext)
  111. PRED16x16(plane_rv40, 8, sse2)
  112. PRED16x16(plane_rv40, 8, ssse3)
  113. PRED16x16(plane_svq3, 8, mmx)
  114. PRED16x16(plane_svq3, 8, mmxext)
  115. PRED16x16(plane_svq3, 8, sse2)
  116. PRED16x16(plane_svq3, 8, ssse3)
  117. PRED16x16(tm_vp8, 8, mmx)
  118. PRED16x16(tm_vp8, 8, mmxext)
  119. PRED16x16(tm_vp8, 8, sse2)
  120. PRED16x16(tm_vp8, 8, avx2)
  121. PRED8x8(top_dc, 8, mmxext)
  122. PRED8x8(dc_rv40, 8, mmxext)
  123. PRED8x8(dc, 8, mmxext)
  124. PRED8x8(vertical, 8, mmx)
  125. PRED8x8(horizontal, 8, mmx)
  126. PRED8x8(horizontal, 8, mmxext)
  127. PRED8x8(horizontal, 8, ssse3)
  128. PRED8x8(plane, 8, mmx)
  129. PRED8x8(plane, 8, mmxext)
  130. PRED8x8(plane, 8, sse2)
  131. PRED8x8(plane, 8, ssse3)
  132. PRED8x8(tm_vp8, 8, mmx)
  133. PRED8x8(tm_vp8, 8, mmxext)
  134. PRED8x8(tm_vp8, 8, sse2)
  135. PRED8x8(tm_vp8, 8, ssse3)
  136. PRED8x8L(top_dc, 8, mmxext)
  137. PRED8x8L(top_dc, 8, ssse3)
  138. PRED8x8L(dc, 8, mmxext)
  139. PRED8x8L(dc, 8, ssse3)
  140. PRED8x8L(horizontal, 8, mmxext)
  141. PRED8x8L(horizontal, 8, ssse3)
  142. PRED8x8L(vertical, 8, mmxext)
  143. PRED8x8L(vertical, 8, ssse3)
  144. PRED8x8L(down_left, 8, mmxext)
  145. PRED8x8L(down_left, 8, sse2)
  146. PRED8x8L(down_left, 8, ssse3)
  147. PRED8x8L(down_right, 8, mmxext)
  148. PRED8x8L(down_right, 8, sse2)
  149. PRED8x8L(down_right, 8, ssse3)
  150. PRED8x8L(vertical_right, 8, mmxext)
  151. PRED8x8L(vertical_right, 8, sse2)
  152. PRED8x8L(vertical_right, 8, ssse3)
  153. PRED8x8L(vertical_left, 8, sse2)
  154. PRED8x8L(vertical_left, 8, ssse3)
  155. PRED8x8L(horizontal_up, 8, mmxext)
  156. PRED8x8L(horizontal_up, 8, ssse3)
  157. PRED8x8L(horizontal_down, 8, mmxext)
  158. PRED8x8L(horizontal_down, 8, sse2)
  159. PRED8x8L(horizontal_down, 8, ssse3)
  160. PRED4x4(dc, 8, mmxext)
  161. PRED4x4(down_left, 8, mmxext)
  162. PRED4x4(down_right, 8, mmxext)
  163. PRED4x4(vertical_left, 8, mmxext)
  164. PRED4x4(vertical_right, 8, mmxext)
  165. PRED4x4(horizontal_up, 8, mmxext)
  166. PRED4x4(horizontal_down, 8, mmxext)
  167. PRED4x4(tm_vp8, 8, mmx)
  168. PRED4x4(tm_vp8, 8, mmxext)
  169. PRED4x4(tm_vp8, 8, ssse3)
  170. PRED4x4(vertical_vp8, 8, mmxext)
  171. av_cold void ff_h264_pred_init_x86(H264PredContext *h, int codec_id,
  172. const int bit_depth,
  173. const int chroma_format_idc)
  174. {
  175. int cpu_flags = av_get_cpu_flags();
  176. if (bit_depth == 8) {
  177. if (EXTERNAL_MMX(cpu_flags)) {
  178. h->pred16x16[VERT_PRED8x8 ] = ff_pred16x16_vertical_8_mmx;
  179. h->pred16x16[HOR_PRED8x8 ] = ff_pred16x16_horizontal_8_mmx;
  180. if (chroma_format_idc <= 1) {
  181. h->pred8x8 [VERT_PRED8x8 ] = ff_pred8x8_vertical_8_mmx;
  182. h->pred8x8 [HOR_PRED8x8 ] = ff_pred8x8_horizontal_8_mmx;
  183. }
  184. if (codec_id == AV_CODEC_ID_VP7 || codec_id == AV_CODEC_ID_VP8) {
  185. h->pred16x16[PLANE_PRED8x8 ] = ff_pred16x16_tm_vp8_8_mmx;
  186. h->pred8x8 [PLANE_PRED8x8 ] = ff_pred8x8_tm_vp8_8_mmx;
  187. h->pred4x4 [TM_VP8_PRED ] = ff_pred4x4_tm_vp8_8_mmx;
  188. } else {
  189. if (chroma_format_idc <= 1)
  190. h->pred8x8 [PLANE_PRED8x8] = ff_pred8x8_plane_8_mmx;
  191. if (codec_id == AV_CODEC_ID_SVQ3) {
  192. if (cpu_flags & AV_CPU_FLAG_CMOV)
  193. h->pred16x16[PLANE_PRED8x8] = ff_pred16x16_plane_svq3_8_mmx;
  194. } else if (codec_id == AV_CODEC_ID_RV40) {
  195. h->pred16x16[PLANE_PRED8x8] = ff_pred16x16_plane_rv40_8_mmx;
  196. } else {
  197. h->pred16x16[PLANE_PRED8x8] = ff_pred16x16_plane_h264_8_mmx;
  198. }
  199. }
  200. }
  201. if (EXTERNAL_MMXEXT(cpu_flags)) {
  202. h->pred16x16[HOR_PRED8x8 ] = ff_pred16x16_horizontal_8_mmxext;
  203. h->pred16x16[DC_PRED8x8 ] = ff_pred16x16_dc_8_mmxext;
  204. if (chroma_format_idc <= 1)
  205. h->pred8x8[HOR_PRED8x8 ] = ff_pred8x8_horizontal_8_mmxext;
  206. h->pred8x8l [TOP_DC_PRED ] = ff_pred8x8l_top_dc_8_mmxext;
  207. h->pred8x8l [DC_PRED ] = ff_pred8x8l_dc_8_mmxext;
  208. h->pred8x8l [HOR_PRED ] = ff_pred8x8l_horizontal_8_mmxext;
  209. h->pred8x8l [VERT_PRED ] = ff_pred8x8l_vertical_8_mmxext;
  210. h->pred8x8l [DIAG_DOWN_RIGHT_PRED ] = ff_pred8x8l_down_right_8_mmxext;
  211. h->pred8x8l [VERT_RIGHT_PRED ] = ff_pred8x8l_vertical_right_8_mmxext;
  212. h->pred8x8l [HOR_UP_PRED ] = ff_pred8x8l_horizontal_up_8_mmxext;
  213. h->pred8x8l [DIAG_DOWN_LEFT_PRED ] = ff_pred8x8l_down_left_8_mmxext;
  214. h->pred8x8l [HOR_DOWN_PRED ] = ff_pred8x8l_horizontal_down_8_mmxext;
  215. h->pred4x4 [DIAG_DOWN_RIGHT_PRED ] = ff_pred4x4_down_right_8_mmxext;
  216. h->pred4x4 [VERT_RIGHT_PRED ] = ff_pred4x4_vertical_right_8_mmxext;
  217. h->pred4x4 [HOR_DOWN_PRED ] = ff_pred4x4_horizontal_down_8_mmxext;
  218. h->pred4x4 [DC_PRED ] = ff_pred4x4_dc_8_mmxext;
  219. if (codec_id == AV_CODEC_ID_VP7 || codec_id == AV_CODEC_ID_VP8 ||
  220. codec_id == AV_CODEC_ID_H264) {
  221. h->pred4x4 [DIAG_DOWN_LEFT_PRED] = ff_pred4x4_down_left_8_mmxext;
  222. }
  223. if (codec_id == AV_CODEC_ID_SVQ3 || codec_id == AV_CODEC_ID_H264) {
  224. h->pred4x4 [VERT_LEFT_PRED ] = ff_pred4x4_vertical_left_8_mmxext;
  225. }
  226. if (codec_id != AV_CODEC_ID_RV40) {
  227. h->pred4x4 [HOR_UP_PRED ] = ff_pred4x4_horizontal_up_8_mmxext;
  228. }
  229. if (codec_id == AV_CODEC_ID_SVQ3 || codec_id == AV_CODEC_ID_H264) {
  230. if (chroma_format_idc <= 1) {
  231. h->pred8x8[TOP_DC_PRED8x8 ] = ff_pred8x8_top_dc_8_mmxext;
  232. h->pred8x8[DC_PRED8x8 ] = ff_pred8x8_dc_8_mmxext;
  233. }
  234. }
  235. if (codec_id == AV_CODEC_ID_VP7 || codec_id == AV_CODEC_ID_VP8) {
  236. h->pred16x16[PLANE_PRED8x8 ] = ff_pred16x16_tm_vp8_8_mmxext;
  237. h->pred8x8 [DC_PRED8x8 ] = ff_pred8x8_dc_rv40_8_mmxext;
  238. h->pred8x8 [PLANE_PRED8x8 ] = ff_pred8x8_tm_vp8_8_mmxext;
  239. h->pred4x4 [TM_VP8_PRED ] = ff_pred4x4_tm_vp8_8_mmxext;
  240. h->pred4x4 [VERT_PRED ] = ff_pred4x4_vertical_vp8_8_mmxext;
  241. } else {
  242. if (chroma_format_idc <= 1)
  243. h->pred8x8 [PLANE_PRED8x8] = ff_pred8x8_plane_8_mmxext;
  244. if (codec_id == AV_CODEC_ID_SVQ3) {
  245. h->pred16x16[PLANE_PRED8x8 ] = ff_pred16x16_plane_svq3_8_mmxext;
  246. } else if (codec_id == AV_CODEC_ID_RV40) {
  247. h->pred16x16[PLANE_PRED8x8 ] = ff_pred16x16_plane_rv40_8_mmxext;
  248. } else {
  249. h->pred16x16[PLANE_PRED8x8 ] = ff_pred16x16_plane_h264_8_mmxext;
  250. }
  251. }
  252. }
  253. if (EXTERNAL_SSE(cpu_flags)) {
  254. h->pred16x16[VERT_PRED8x8] = ff_pred16x16_vertical_8_sse;
  255. }
  256. if (EXTERNAL_SSE2(cpu_flags)) {
  257. h->pred16x16[DC_PRED8x8 ] = ff_pred16x16_dc_8_sse2;
  258. h->pred8x8l [DIAG_DOWN_LEFT_PRED ] = ff_pred8x8l_down_left_8_sse2;
  259. h->pred8x8l [DIAG_DOWN_RIGHT_PRED ] = ff_pred8x8l_down_right_8_sse2;
  260. h->pred8x8l [VERT_RIGHT_PRED ] = ff_pred8x8l_vertical_right_8_sse2;
  261. h->pred8x8l [VERT_LEFT_PRED ] = ff_pred8x8l_vertical_left_8_sse2;
  262. h->pred8x8l [HOR_DOWN_PRED ] = ff_pred8x8l_horizontal_down_8_sse2;
  263. if (codec_id == AV_CODEC_ID_VP7 || codec_id == AV_CODEC_ID_VP8) {
  264. h->pred16x16[PLANE_PRED8x8 ] = ff_pred16x16_tm_vp8_8_sse2;
  265. h->pred8x8 [PLANE_PRED8x8 ] = ff_pred8x8_tm_vp8_8_sse2;
  266. } else {
  267. if (chroma_format_idc <= 1)
  268. h->pred8x8 [PLANE_PRED8x8] = ff_pred8x8_plane_8_sse2;
  269. if (codec_id == AV_CODEC_ID_SVQ3) {
  270. h->pred16x16[PLANE_PRED8x8] = ff_pred16x16_plane_svq3_8_sse2;
  271. } else if (codec_id == AV_CODEC_ID_RV40) {
  272. h->pred16x16[PLANE_PRED8x8] = ff_pred16x16_plane_rv40_8_sse2;
  273. } else {
  274. h->pred16x16[PLANE_PRED8x8] = ff_pred16x16_plane_h264_8_sse2;
  275. }
  276. }
  277. }
  278. if (EXTERNAL_SSSE3(cpu_flags)) {
  279. h->pred16x16[HOR_PRED8x8 ] = ff_pred16x16_horizontal_8_ssse3;
  280. h->pred16x16[DC_PRED8x8 ] = ff_pred16x16_dc_8_ssse3;
  281. if (chroma_format_idc <= 1)
  282. h->pred8x8 [HOR_PRED8x8 ] = ff_pred8x8_horizontal_8_ssse3;
  283. h->pred8x8l [TOP_DC_PRED ] = ff_pred8x8l_top_dc_8_ssse3;
  284. h->pred8x8l [DC_PRED ] = ff_pred8x8l_dc_8_ssse3;
  285. h->pred8x8l [HOR_PRED ] = ff_pred8x8l_horizontal_8_ssse3;
  286. h->pred8x8l [VERT_PRED ] = ff_pred8x8l_vertical_8_ssse3;
  287. h->pred8x8l [DIAG_DOWN_LEFT_PRED ] = ff_pred8x8l_down_left_8_ssse3;
  288. h->pred8x8l [DIAG_DOWN_RIGHT_PRED ] = ff_pred8x8l_down_right_8_ssse3;
  289. h->pred8x8l [VERT_RIGHT_PRED ] = ff_pred8x8l_vertical_right_8_ssse3;
  290. h->pred8x8l [VERT_LEFT_PRED ] = ff_pred8x8l_vertical_left_8_ssse3;
  291. h->pred8x8l [HOR_UP_PRED ] = ff_pred8x8l_horizontal_up_8_ssse3;
  292. h->pred8x8l [HOR_DOWN_PRED ] = ff_pred8x8l_horizontal_down_8_ssse3;
  293. if (codec_id == AV_CODEC_ID_VP7 || codec_id == AV_CODEC_ID_VP8) {
  294. h->pred8x8 [PLANE_PRED8x8 ] = ff_pred8x8_tm_vp8_8_ssse3;
  295. h->pred4x4 [TM_VP8_PRED ] = ff_pred4x4_tm_vp8_8_ssse3;
  296. } else {
  297. if (chroma_format_idc <= 1)
  298. h->pred8x8 [PLANE_PRED8x8] = ff_pred8x8_plane_8_ssse3;
  299. if (codec_id == AV_CODEC_ID_SVQ3) {
  300. h->pred16x16[PLANE_PRED8x8] = ff_pred16x16_plane_svq3_8_ssse3;
  301. } else if (codec_id == AV_CODEC_ID_RV40) {
  302. h->pred16x16[PLANE_PRED8x8] = ff_pred16x16_plane_rv40_8_ssse3;
  303. } else {
  304. h->pred16x16[PLANE_PRED8x8] = ff_pred16x16_plane_h264_8_ssse3;
  305. }
  306. }
  307. }
  308. if(EXTERNAL_AVX2(cpu_flags)){
  309. if (codec_id == AV_CODEC_ID_VP8) {
  310. h->pred16x16[PLANE_PRED8x8 ] = ff_pred16x16_tm_vp8_8_avx2;
  311. }
  312. }
  313. } else if (bit_depth == 10) {
  314. if (EXTERNAL_MMXEXT(cpu_flags)) {
  315. h->pred4x4[DC_PRED ] = ff_pred4x4_dc_10_mmxext;
  316. h->pred4x4[HOR_UP_PRED ] = ff_pred4x4_horizontal_up_10_mmxext;
  317. if (chroma_format_idc <= 1)
  318. h->pred8x8[DC_PRED8x8 ] = ff_pred8x8_dc_10_mmxext;
  319. h->pred8x8l[DC_128_PRED ] = ff_pred8x8l_128_dc_10_mmxext;
  320. h->pred16x16[DC_PRED8x8 ] = ff_pred16x16_dc_10_mmxext;
  321. h->pred16x16[TOP_DC_PRED8x8 ] = ff_pred16x16_top_dc_10_mmxext;
  322. h->pred16x16[DC_128_PRED8x8 ] = ff_pred16x16_128_dc_10_mmxext;
  323. h->pred16x16[LEFT_DC_PRED8x8 ] = ff_pred16x16_left_dc_10_mmxext;
  324. h->pred16x16[VERT_PRED8x8 ] = ff_pred16x16_vertical_10_mmxext;
  325. h->pred16x16[HOR_PRED8x8 ] = ff_pred16x16_horizontal_10_mmxext;
  326. }
  327. if (EXTERNAL_SSE2(cpu_flags)) {
  328. h->pred4x4[DIAG_DOWN_LEFT_PRED ] = ff_pred4x4_down_left_10_sse2;
  329. h->pred4x4[DIAG_DOWN_RIGHT_PRED] = ff_pred4x4_down_right_10_sse2;
  330. h->pred4x4[VERT_LEFT_PRED ] = ff_pred4x4_vertical_left_10_sse2;
  331. h->pred4x4[VERT_RIGHT_PRED ] = ff_pred4x4_vertical_right_10_sse2;
  332. h->pred4x4[HOR_DOWN_PRED ] = ff_pred4x4_horizontal_down_10_sse2;
  333. if (chroma_format_idc <= 1) {
  334. h->pred8x8[DC_PRED8x8 ] = ff_pred8x8_dc_10_sse2;
  335. h->pred8x8[TOP_DC_PRED8x8 ] = ff_pred8x8_top_dc_10_sse2;
  336. h->pred8x8[PLANE_PRED8x8 ] = ff_pred8x8_plane_10_sse2;
  337. h->pred8x8[VERT_PRED8x8 ] = ff_pred8x8_vertical_10_sse2;
  338. h->pred8x8[HOR_PRED8x8 ] = ff_pred8x8_horizontal_10_sse2;
  339. }
  340. h->pred8x8l[VERT_PRED ] = ff_pred8x8l_vertical_10_sse2;
  341. h->pred8x8l[HOR_PRED ] = ff_pred8x8l_horizontal_10_sse2;
  342. h->pred8x8l[DC_PRED ] = ff_pred8x8l_dc_10_sse2;
  343. h->pred8x8l[DC_128_PRED ] = ff_pred8x8l_128_dc_10_sse2;
  344. h->pred8x8l[TOP_DC_PRED ] = ff_pred8x8l_top_dc_10_sse2;
  345. h->pred8x8l[DIAG_DOWN_LEFT_PRED ] = ff_pred8x8l_down_left_10_sse2;
  346. h->pred8x8l[DIAG_DOWN_RIGHT_PRED] = ff_pred8x8l_down_right_10_sse2;
  347. h->pred8x8l[VERT_RIGHT_PRED ] = ff_pred8x8l_vertical_right_10_sse2;
  348. h->pred8x8l[HOR_UP_PRED ] = ff_pred8x8l_horizontal_up_10_sse2;
  349. h->pred16x16[DC_PRED8x8 ] = ff_pred16x16_dc_10_sse2;
  350. h->pred16x16[TOP_DC_PRED8x8 ] = ff_pred16x16_top_dc_10_sse2;
  351. h->pred16x16[DC_128_PRED8x8 ] = ff_pred16x16_128_dc_10_sse2;
  352. h->pred16x16[LEFT_DC_PRED8x8 ] = ff_pred16x16_left_dc_10_sse2;
  353. h->pred16x16[VERT_PRED8x8 ] = ff_pred16x16_vertical_10_sse2;
  354. h->pred16x16[HOR_PRED8x8 ] = ff_pred16x16_horizontal_10_sse2;
  355. }
  356. if (EXTERNAL_SSSE3(cpu_flags)) {
  357. h->pred4x4[DIAG_DOWN_RIGHT_PRED] = ff_pred4x4_down_right_10_ssse3;
  358. h->pred4x4[VERT_RIGHT_PRED ] = ff_pred4x4_vertical_right_10_ssse3;
  359. h->pred4x4[HOR_DOWN_PRED ] = ff_pred4x4_horizontal_down_10_ssse3;
  360. h->pred8x8l[HOR_PRED ] = ff_pred8x8l_horizontal_10_ssse3;
  361. h->pred8x8l[DIAG_DOWN_LEFT_PRED ] = ff_pred8x8l_down_left_10_ssse3;
  362. h->pred8x8l[DIAG_DOWN_RIGHT_PRED] = ff_pred8x8l_down_right_10_ssse3;
  363. h->pred8x8l[VERT_RIGHT_PRED ] = ff_pred8x8l_vertical_right_10_ssse3;
  364. h->pred8x8l[HOR_UP_PRED ] = ff_pred8x8l_horizontal_up_10_ssse3;
  365. }
  366. if (EXTERNAL_AVX(cpu_flags)) {
  367. h->pred4x4[DIAG_DOWN_LEFT_PRED ] = ff_pred4x4_down_left_10_avx;
  368. h->pred4x4[DIAG_DOWN_RIGHT_PRED] = ff_pred4x4_down_right_10_avx;
  369. h->pred4x4[VERT_LEFT_PRED ] = ff_pred4x4_vertical_left_10_avx;
  370. h->pred4x4[VERT_RIGHT_PRED ] = ff_pred4x4_vertical_right_10_avx;
  371. h->pred4x4[HOR_DOWN_PRED ] = ff_pred4x4_horizontal_down_10_avx;
  372. h->pred8x8l[VERT_PRED ] = ff_pred8x8l_vertical_10_avx;
  373. h->pred8x8l[HOR_PRED ] = ff_pred8x8l_horizontal_10_avx;
  374. h->pred8x8l[DC_PRED ] = ff_pred8x8l_dc_10_avx;
  375. h->pred8x8l[TOP_DC_PRED ] = ff_pred8x8l_top_dc_10_avx;
  376. h->pred8x8l[DIAG_DOWN_RIGHT_PRED] = ff_pred8x8l_down_right_10_avx;
  377. h->pred8x8l[DIAG_DOWN_LEFT_PRED ] = ff_pred8x8l_down_left_10_avx;
  378. h->pred8x8l[VERT_RIGHT_PRED ] = ff_pred8x8l_vertical_right_10_avx;
  379. h->pred8x8l[HOR_UP_PRED ] = ff_pred8x8l_horizontal_up_10_avx;
  380. }
  381. }
  382. }