Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2)

Side by Side Diff: third_party/libvpx/source/config/linux/ia32/vp9_rtcd.h

Issue 2708273003: Roll src/third_party/libvpx/source/libvpx/ 91f87e751..4d4231352 (50 commits). (Closed)
Patch Set: Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 #ifndef VP9_RTCD_H_ 1 #ifndef VP9_RTCD_H_
2 #define VP9_RTCD_H_ 2 #define VP9_RTCD_H_
3 3
4 #ifdef RTCD_C 4 #ifdef RTCD_C
5 #define RTCD_EXTERN 5 #define RTCD_EXTERN
6 #else 6 #else
7 #define RTCD_EXTERN extern 7 #define RTCD_EXTERN extern
8 #endif 8 #endif
9 9
10 /* 10 /*
(...skipping 12 matching lines...) Expand all
23 struct search_site_config; 23 struct search_site_config;
24 struct mv; 24 struct mv;
25 union int_mv; 25 union int_mv;
26 struct yv12_buffer_config; 26 struct yv12_buffer_config;
27 27
28 #ifdef __cplusplus 28 #ifdef __cplusplus
29 extern "C" { 29 extern "C" {
30 #endif 30 #endif
31 31
32 int64_t vp9_block_error_c(const tran_low_t *coeff, const tran_low_t *dqcoeff, in tptr_t block_size, int64_t *ssz); 32 int64_t vp9_block_error_c(const tran_low_t *coeff, const tran_low_t *dqcoeff, in tptr_t block_size, int64_t *ssz);
33 #define vp9_block_error vp9_block_error_c 33 int64_t vp9_block_error_avx2(const tran_low_t *coeff, const tran_low_t *dqcoeff, intptr_t block_size, int64_t *ssz);
34 RTCD_EXTERN int64_t (*vp9_block_error)(const tran_low_t *coeff, const tran_low_t *dqcoeff, intptr_t block_size, int64_t *ssz);
34 35
35 int64_t vp9_block_error_fp_c(const tran_low_t *coeff, const tran_low_t *dqcoeff, int block_size); 36 int64_t vp9_block_error_fp_c(const tran_low_t *coeff, const tran_low_t *dqcoeff, int block_size);
36 int64_t vp9_block_error_fp_sse2(const tran_low_t *coeff, const tran_low_t *dqcoe ff, int block_size); 37 int64_t vp9_block_error_fp_sse2(const tran_low_t *coeff, const tran_low_t *dqcoe ff, int block_size);
37 RTCD_EXTERN int64_t (*vp9_block_error_fp)(const tran_low_t *coeff, const tran_lo w_t *dqcoeff, int block_size); 38 RTCD_EXTERN int64_t (*vp9_block_error_fp)(const tran_low_t *coeff, const tran_lo w_t *dqcoeff, int block_size);
38 39
39 int vp9_denoiser_filter_c(const uint8_t *sig, int sig_stride, const uint8_t *mc_ avg, int mc_avg_stride, uint8_t *avg, int avg_stride, int increase_denoising, BL OCK_SIZE bs, int motion_magnitude); 40 int vp9_denoiser_filter_c(const uint8_t *sig, int sig_stride, const uint8_t *mc_ avg, int mc_avg_stride, uint8_t *avg, int avg_stride, int increase_denoising, BL OCK_SIZE bs, int motion_magnitude);
40 int vp9_denoiser_filter_sse2(const uint8_t *sig, int sig_stride, const uint8_t * mc_avg, int mc_avg_stride, uint8_t *avg, int avg_stride, int increase_denoising, BLOCK_SIZE bs, int motion_magnitude); 41 int vp9_denoiser_filter_sse2(const uint8_t *sig, int sig_stride, const uint8_t * mc_avg, int mc_avg_stride, uint8_t *avg, int avg_stride, int increase_denoising, BLOCK_SIZE bs, int motion_magnitude);
41 RTCD_EXTERN int (*vp9_denoiser_filter)(const uint8_t *sig, int sig_stride, const uint8_t *mc_avg, int mc_avg_stride, uint8_t *avg, int avg_stride, int increase_ denoising, BLOCK_SIZE bs, int motion_magnitude); 42 RTCD_EXTERN int (*vp9_denoiser_filter)(const uint8_t *sig, int sig_stride, const uint8_t *mc_avg, int mc_avg_stride, uint8_t *avg, int avg_stride, int increase_ denoising, BLOCK_SIZE bs, int motion_magnitude);
42 43
43 int vp9_diamond_search_sad_c(const struct macroblock *x, const struct search_sit e_config *cfg, struct mv *ref_mv, struct mv *best_mv, int search_param, int sad _per_bit, int *num00, const struct vp9_variance_vtable *fn_ptr, const struct mv *center_mv); 44 int vp9_diamond_search_sad_c(const struct macroblock *x, const struct search_sit e_config *cfg, struct mv *ref_mv, struct mv *best_mv, int search_param, int sad _per_bit, int *num00, const struct vp9_variance_vtable *fn_ptr, const struct mv *center_mv);
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after
131 132
132 void vp9_iht4x4_16_add_c(const tran_low_t *input, uint8_t *dest, int stride, int tx_type); 133 void vp9_iht4x4_16_add_c(const tran_low_t *input, uint8_t *dest, int stride, int tx_type);
133 void vp9_iht4x4_16_add_sse2(const tran_low_t *input, uint8_t *dest, int stride, int tx_type); 134 void vp9_iht4x4_16_add_sse2(const tran_low_t *input, uint8_t *dest, int stride, int tx_type);
134 RTCD_EXTERN void (*vp9_iht4x4_16_add)(const tran_low_t *input, uint8_t *dest, in t stride, int tx_type); 135 RTCD_EXTERN void (*vp9_iht4x4_16_add)(const tran_low_t *input, uint8_t *dest, in t stride, int tx_type);
135 136
136 void vp9_iht8x8_64_add_c(const tran_low_t *input, uint8_t *dest, int stride, int tx_type); 137 void vp9_iht8x8_64_add_c(const tran_low_t *input, uint8_t *dest, int stride, int tx_type);
137 void vp9_iht8x8_64_add_sse2(const tran_low_t *input, uint8_t *dest, int stride, int tx_type); 138 void vp9_iht8x8_64_add_sse2(const tran_low_t *input, uint8_t *dest, int stride, int tx_type);
138 RTCD_EXTERN void (*vp9_iht8x8_64_add)(const tran_low_t *input, uint8_t *dest, in t stride, int tx_type); 139 RTCD_EXTERN void (*vp9_iht8x8_64_add)(const tran_low_t *input, uint8_t *dest, in t stride, int tx_type);
139 140
140 void vp9_quantize_fp_c(const tran_low_t *coeff_ptr, intptr_t n_coeffs, int skip_ block, const int16_t *zbin_ptr, const int16_t *round_ptr, const int16_t *quant_p tr, const int16_t *quant_shift_ptr, tran_low_t *qcoeff_ptr, tran_low_t *dqcoeff_ ptr, const int16_t *dequant_ptr, uint16_t *eob_ptr, const int16_t *scan, const i nt16_t *iscan); 141 void vp9_quantize_fp_c(const tran_low_t *coeff_ptr, intptr_t n_coeffs, int skip_ block, const int16_t *zbin_ptr, const int16_t *round_ptr, const int16_t *quant_p tr, const int16_t *quant_shift_ptr, tran_low_t *qcoeff_ptr, tran_low_t *dqcoeff_ ptr, const int16_t *dequant_ptr, uint16_t *eob_ptr, const int16_t *scan, const i nt16_t *iscan);
141 #define vp9_quantize_fp vp9_quantize_fp_c 142 void vp9_quantize_fp_sse2(const tran_low_t *coeff_ptr, intptr_t n_coeffs, int sk ip_block, const int16_t *zbin_ptr, const int16_t *round_ptr, const int16_t *quan t_ptr, const int16_t *quant_shift_ptr, tran_low_t *qcoeff_ptr, tran_low_t *dqcoe ff_ptr, const int16_t *dequant_ptr, uint16_t *eob_ptr, const int16_t *scan, cons t int16_t *iscan);
143 RTCD_EXTERN void (*vp9_quantize_fp)(const tran_low_t *coeff_ptr, intptr_t n_coef fs, int skip_block, const int16_t *zbin_ptr, const int16_t *round_ptr, const int 16_t *quant_ptr, const int16_t *quant_shift_ptr, tran_low_t *qcoeff_ptr, tran_lo w_t *dqcoeff_ptr, const int16_t *dequant_ptr, uint16_t *eob_ptr, const int16_t * scan, const int16_t *iscan);
142 144
143 void vp9_quantize_fp_32x32_c(const tran_low_t *coeff_ptr, intptr_t n_coeffs, int skip_block, const int16_t *zbin_ptr, const int16_t *round_ptr, const int16_t *q uant_ptr, const int16_t *quant_shift_ptr, tran_low_t *qcoeff_ptr, tran_low_t *dq coeff_ptr, const int16_t *dequant_ptr, uint16_t *eob_ptr, const int16_t *scan, c onst int16_t *iscan); 145 void vp9_quantize_fp_32x32_c(const tran_low_t *coeff_ptr, intptr_t n_coeffs, int skip_block, const int16_t *zbin_ptr, const int16_t *round_ptr, const int16_t *q uant_ptr, const int16_t *quant_shift_ptr, tran_low_t *qcoeff_ptr, tran_low_t *dq coeff_ptr, const int16_t *dequant_ptr, uint16_t *eob_ptr, const int16_t *scan, c onst int16_t *iscan);
144 #define vp9_quantize_fp_32x32 vp9_quantize_fp_32x32_c 146 #define vp9_quantize_fp_32x32 vp9_quantize_fp_32x32_c
145 147
146 void vp9_temporal_filter_apply_c(uint8_t *frame1, unsigned int stride, uint8_t * frame2, unsigned int block_width, unsigned int block_height, int strength, int f ilter_weight, unsigned int *accumulator, uint16_t *count); 148 void vp9_temporal_filter_apply_c(uint8_t *frame1, unsigned int stride, uint8_t * frame2, unsigned int block_width, unsigned int block_height, int strength, int f ilter_weight, unsigned int *accumulator, uint16_t *count);
147 void vp9_temporal_filter_apply_sse2(uint8_t *frame1, unsigned int stride, uint8_ t *frame2, unsigned int block_width, unsigned int block_height, int strength, in t filter_weight, unsigned int *accumulator, uint16_t *count); 149 void vp9_temporal_filter_apply_sse2(uint8_t *frame1, unsigned int stride, uint8_ t *frame2, unsigned int block_width, unsigned int block_height, int strength, in t filter_weight, unsigned int *accumulator, uint16_t *count);
148 RTCD_EXTERN void (*vp9_temporal_filter_apply)(uint8_t *frame1, unsigned int stri de, uint8_t *frame2, unsigned int block_width, unsigned int block_height, int st rength, int filter_weight, unsigned int *accumulator, uint16_t *count); 150 RTCD_EXTERN void (*vp9_temporal_filter_apply)(uint8_t *frame1, unsigned int stri de, uint8_t *frame2, unsigned int block_width, unsigned int block_height, int st rength, int filter_weight, unsigned int *accumulator, uint16_t *count);
149 151
150 void vp9_rtcd(void); 152 void vp9_rtcd(void);
151 153
152 #ifdef RTCD_C 154 #ifdef RTCD_C
153 #include "vpx_ports/x86.h" 155 #include "vpx_ports/x86.h"
154 static void setup_rtcd_internal(void) 156 static void setup_rtcd_internal(void)
155 { 157 {
156 int flags = x86_simd_caps(); 158 int flags = x86_simd_caps();
157 159
158 (void)flags; 160 (void)flags;
159 161
162 vp9_block_error = vp9_block_error_c;
163 if (flags & HAS_AVX2) vp9_block_error = vp9_block_error_avx2;
160 vp9_block_error_fp = vp9_block_error_fp_c; 164 vp9_block_error_fp = vp9_block_error_fp_c;
161 if (flags & HAS_SSE2) vp9_block_error_fp = vp9_block_error_fp_sse2; 165 if (flags & HAS_SSE2) vp9_block_error_fp = vp9_block_error_fp_sse2;
162 vp9_denoiser_filter = vp9_denoiser_filter_c; 166 vp9_denoiser_filter = vp9_denoiser_filter_c;
163 if (flags & HAS_SSE2) vp9_denoiser_filter = vp9_denoiser_filter_sse2; 167 if (flags & HAS_SSE2) vp9_denoiser_filter = vp9_denoiser_filter_sse2;
164 vp9_diamond_search_sad = vp9_diamond_search_sad_c; 168 vp9_diamond_search_sad = vp9_diamond_search_sad_c;
165 if (flags & HAS_AVX) vp9_diamond_search_sad = vp9_diamond_search_sad_avx; 169 if (flags & HAS_AVX) vp9_diamond_search_sad = vp9_diamond_search_sad_avx;
166 vp9_fdct8x8_quant = vp9_fdct8x8_quant_c; 170 vp9_fdct8x8_quant = vp9_fdct8x8_quant_c;
167 if (flags & HAS_SSSE3) vp9_fdct8x8_quant = vp9_fdct8x8_quant_ssse3; 171 if (flags & HAS_SSSE3) vp9_fdct8x8_quant = vp9_fdct8x8_quant_ssse3;
168 vp9_fht16x16 = vp9_fht16x16_c; 172 vp9_fht16x16 = vp9_fht16x16_c;
169 if (flags & HAS_SSE2) vp9_fht16x16 = vp9_fht16x16_sse2; 173 if (flags & HAS_SSE2) vp9_fht16x16 = vp9_fht16x16_sse2;
(...skipping 14 matching lines...) Expand all
184 if (flags & HAS_SSE2) vp9_highbd_block_error = vp9_highbd_block_error_sse2; 188 if (flags & HAS_SSE2) vp9_highbd_block_error = vp9_highbd_block_error_sse2;
185 vp9_highbd_block_error_8bit = vp9_highbd_block_error_8bit_c; 189 vp9_highbd_block_error_8bit = vp9_highbd_block_error_8bit_c;
186 if (flags & HAS_SSE2) vp9_highbd_block_error_8bit = vp9_highbd_block_error_8 bit_sse2; 190 if (flags & HAS_SSE2) vp9_highbd_block_error_8bit = vp9_highbd_block_error_8 bit_sse2;
187 if (flags & HAS_AVX) vp9_highbd_block_error_8bit = vp9_highbd_block_error_8b it_avx; 191 if (flags & HAS_AVX) vp9_highbd_block_error_8bit = vp9_highbd_block_error_8b it_avx;
188 vp9_iht16x16_256_add = vp9_iht16x16_256_add_c; 192 vp9_iht16x16_256_add = vp9_iht16x16_256_add_c;
189 if (flags & HAS_SSE2) vp9_iht16x16_256_add = vp9_iht16x16_256_add_sse2; 193 if (flags & HAS_SSE2) vp9_iht16x16_256_add = vp9_iht16x16_256_add_sse2;
190 vp9_iht4x4_16_add = vp9_iht4x4_16_add_c; 194 vp9_iht4x4_16_add = vp9_iht4x4_16_add_c;
191 if (flags & HAS_SSE2) vp9_iht4x4_16_add = vp9_iht4x4_16_add_sse2; 195 if (flags & HAS_SSE2) vp9_iht4x4_16_add = vp9_iht4x4_16_add_sse2;
192 vp9_iht8x8_64_add = vp9_iht8x8_64_add_c; 196 vp9_iht8x8_64_add = vp9_iht8x8_64_add_c;
193 if (flags & HAS_SSE2) vp9_iht8x8_64_add = vp9_iht8x8_64_add_sse2; 197 if (flags & HAS_SSE2) vp9_iht8x8_64_add = vp9_iht8x8_64_add_sse2;
198 vp9_quantize_fp = vp9_quantize_fp_c;
199 if (flags & HAS_SSE2) vp9_quantize_fp = vp9_quantize_fp_sse2;
194 vp9_temporal_filter_apply = vp9_temporal_filter_apply_c; 200 vp9_temporal_filter_apply = vp9_temporal_filter_apply_c;
195 if (flags & HAS_SSE2) vp9_temporal_filter_apply = vp9_temporal_filter_apply_ sse2; 201 if (flags & HAS_SSE2) vp9_temporal_filter_apply = vp9_temporal_filter_apply_ sse2;
196 } 202 }
197 #endif 203 #endif
198 204
199 #ifdef __cplusplus 205 #ifdef __cplusplus
200 } // extern "C" 206 } // extern "C"
201 #endif 207 #endif
202 208
203 #endif 209 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698