Go to the documentation of this file.
38 #if HAVE_AVX2_EXTERNAL
45 #if HAVE_AVX2_EXTERNAL
56 #if HAVE_AVX2_EXTERNAL
65 #define decl_lpf_func(dir, wd, bpp, opt) \
66 void ff_vp9_loop_filter_##dir##_##wd##_##bpp##_##opt(uint8_t *dst, ptrdiff_t stride, \
69 #define decl_lpf_funcs(dir, wd, bpp) \
70 decl_lpf_func(dir, wd, bpp, sse2); \
71 decl_lpf_func(dir, wd, bpp, ssse3); \
72 decl_lpf_func(dir, wd, bpp, avx)
74 #define decl_lpf_funcs_wd(dir) \
75 decl_lpf_funcs(dir, 4, BPC); \
76 decl_lpf_funcs(dir, 8, BPC); \
77 decl_lpf_funcs(dir, 16, BPC)
82 #define lpf_16_wrapper(dir, off, bpp, opt) \
83 static void loop_filter_##dir##_16_##bpp##_##opt(uint8_t *dst, ptrdiff_t stride, \
84 int E, int I, int H) \
86 ff_vp9_loop_filter_##dir##_16_##bpp##_##opt(dst, stride, E, I, H); \
87 ff_vp9_loop_filter_##dir##_16_##bpp##_##opt(dst + off, stride, E, I, H); \
90 #define lpf_16_wrappers(bpp, opt) \
91 lpf_16_wrapper(h, 8 * stride, bpp, opt) \
92 lpf_16_wrapper(v, 16, bpp, opt)
98 #define lpf_mix2_wrapper(dir, off, wd1, wd2, bpp, opt) \
99 static void loop_filter_##dir##_##wd1##wd2##_##bpp##_##opt(uint8_t *dst, ptrdiff_t stride, \
100 int E, int I, int H) \
102 ff_vp9_loop_filter_##dir##_##wd1##_##bpp##_##opt(dst, stride, \
103 E & 0xff, I & 0xff, H & 0xff); \
104 ff_vp9_loop_filter_##dir##_##wd2##_##bpp##_##opt(dst + off, stride, \
105 E >> 8, I >> 8, H >> 8); \
108 #define lpf_mix2_wrappers(wd1, wd2, bpp, opt) \
109 lpf_mix2_wrapper(h, 8 * stride, wd1, wd2, bpp, opt) \
110 lpf_mix2_wrapper(v, 16, wd1, wd2, bpp, opt)
112 #define lpf_mix2_wrappers_set(bpp, opt) \
113 lpf_mix2_wrappers(4, 4, bpp, opt) \
114 lpf_mix2_wrappers(4, 8, bpp, opt) \
115 lpf_mix2_wrappers(8, 4, bpp, opt) \
116 lpf_mix2_wrappers(8, 8, bpp, opt) \
144 #define init_lpf_8_func(idx1, idx2, dir, wd, bpp, opt) \
145 dsp->loop_filter_8[idx1][idx2] = ff_vp9_loop_filter_##dir##_##wd##_##bpp##_##opt
146 #define init_lpf_16_func(idx, dir, bpp, opt) \
147 dsp->loop_filter_16[idx] = loop_filter_##dir##_16_##bpp##_##opt
148 #define init_lpf_mix2_func(idx1, idx2, idx3, dir, wd1, wd2, bpp, opt) \
149 dsp->loop_filter_mix2[idx1][idx2][idx3] = loop_filter_##dir##_##wd1##wd2##_##bpp##_##opt
151 #define init_lpf_funcs(bpp, opt) \
152 init_lpf_8_func(0, 0, h, 4, bpp, opt); \
153 init_lpf_8_func(0, 1, v, 4, bpp, opt); \
154 init_lpf_8_func(1, 0, h, 8, bpp, opt); \
155 init_lpf_8_func(1, 1, v, 8, bpp, opt); \
156 init_lpf_8_func(2, 0, h, 16, bpp, opt); \
157 init_lpf_8_func(2, 1, v, 16, bpp, opt); \
158 init_lpf_16_func(0, h, bpp, opt); \
159 init_lpf_16_func(1, v, bpp, opt); \
160 init_lpf_mix2_func(0, 0, 0, h, 4, 4, bpp, opt); \
161 init_lpf_mix2_func(0, 1, 0, h, 4, 8, bpp, opt); \
162 init_lpf_mix2_func(1, 0, 0, h, 8, 4, bpp, opt); \
163 init_lpf_mix2_func(1, 1, 0, h, 8, 8, bpp, opt); \
164 init_lpf_mix2_func(0, 0, 1, v, 4, 4, bpp, opt); \
165 init_lpf_mix2_func(0, 1, 1, v, 4, 8, bpp, opt); \
166 init_lpf_mix2_func(1, 0, 1, v, 8, 4, bpp, opt); \
167 init_lpf_mix2_func(1, 1, 1, v, 8, 8, bpp, opt)
169 #define init_itx_func(idxa, idxb, typea, typeb, size, bpp, opt) \
170 dsp->itxfm_add[idxa][idxb] = \
171 cat(ff_vp9_##typea##_##typeb##_##size##x##size##_add_, bpp, _##opt);
172 #define init_itx_func_one(idx, typea, typeb, size, bpp, opt) \
173 init_itx_func(idx, DCT_DCT, typea, typeb, size, bpp, opt); \
174 init_itx_func(idx, ADST_DCT, typea, typeb, size, bpp, opt); \
175 init_itx_func(idx, DCT_ADST, typea, typeb, size, bpp, opt); \
176 init_itx_func(idx, ADST_ADST, typea, typeb, size, bpp, opt)
177 #define init_itx_funcs(idx, size, bpp, opt) \
178 init_itx_func(idx, DCT_DCT, idct, idct, size, bpp, opt); \
179 init_itx_func(idx, ADST_DCT, idct, iadst, size, bpp, opt); \
180 init_itx_func(idx, DCT_ADST, iadst, idct, size, bpp, opt); \
181 init_itx_func(idx, ADST_ADST, iadst, iadst, size, bpp, opt); \
226 #if HAVE_AVX2_EXTERNAL
234 #if ARCH_X86_64 && BPC == 10
mc_rep_funcs(mc_rep_funcs(16, decl_itxfm_funcs(8, mc_rep_funcs(16, mc_rep_funcs(sse2, mc_rep_funcs(int16_t, mc_rep_funcs(16, mc_rep_funcs(BPC)
const int16_t ff_filters_16bpp[3][15][4][16]
#define EXTERNAL_AVX2_FAST(flags)
#define init_itx_func_one(idx, typea, typeb, size, bpp, opt)
#define init_8_16_32_ipred_funcs(type, enum, bpp, opt)
int av_get_cpu_flags(void)
Return the flags which specify extensions supported by the CPU.
#define lpf_mix2_wrappers_set(bpp, opt)
static atomic_int cpu_flags
#define init_lpf_funcs(bpp, opt)
decl_mc_funcs(4, sse2, int16_t, 16, BPC)
#define filters_8tap_1d_fn3(op, bpp, opt4, opt8, f_opt)
static void idct(int16_t block[64])
#define decl_itxfm_func(typea, typeb, size, bpp, opt)
#define decl_itxfm_funcs(size, bpp, opt)
#define init_subpel3_32_64(idx, type, bpp, opt)
#define decl_ipred_fns(type, bpp, opt4, opt8_16_32)
#define filters_8tap_2d_fn2(op, align, bpp, bytes, opt4, opt8, f_opt)
void ff_vp9dsp_init_16bpp_x86(VP9DSPContext *dsp)
#define init_subpel3(idx, type)
#define init_itx_func(idxa, idxb, typea, typeb, size, bpp, opt)
#define EXTERNAL_SSE2(flags)
#define filters_8tap_2d_fn(op, sz, align, bpp, bytes, opt, f_opt)
#define filters_8tap_1d_fn2(op, sz, bpp, opt, f_opt)
#define init_ipred_func(type, enum, sz, bpp, opt)
#define init_itx_funcs(idx, size, bpp, opt)
#define decl_lpf_funcs_wd(dir)
#define EXTERNAL_AVX(flags)
#define EXTERNAL_AVX512ICL(flags)
#define lpf_16_wrappers(bpp, opt)
#define EXTERNAL_SSSE3(flags)
#define EXTERNAL_MMXEXT(flags)
#define init_subpel2(idx, idxh, idxv, dir, type)