From fc9deb6b0c0b47900ce3c5c3abdc0eeaffdc79ac Mon Sep 17 00:00:00 2001 From: Yaowu Xu Date: Mon, 9 May 2016 11:50:15 -0700 Subject: [PATCH] Remove "const" for parameters passed by value This commit removes const from parameters that are passed by value for consistency in code style. Change-Id: I2947c4e9cc6e809c4b9b4c162046e45127b8a41c --- vp10/common/vp10_rtcd_defs.pl | 14 +++++++------- vp10/encoder/quantize.c | 4 ++-- vp10/encoder/x86/highbd_fwd_txfm_sse4.c | 5 ++--- 3 files changed, 11 insertions(+), 12 deletions(-) diff --git a/vp10/common/vp10_rtcd_defs.pl b/vp10/common/vp10_rtcd_defs.pl index 0e59bfe2f..d843dfe90 100644 --- a/vp10/common/vp10_rtcd_defs.pl +++ b/vp10/common/vp10_rtcd_defs.pl @@ -614,15 +614,15 @@ if (vpx_config("CONFIG_VP9_HIGHBITDEPTH") eq "yes") { if (vpx_config("CONFIG_VP9_HIGHBITDEPTH") eq "yes") { #fwd txfm - add_proto qw/void vp10_fwd_txfm2d_4x4/, "const int16_t *input, int32_t *output, const int stride, int tx_type, const int bd"; + add_proto qw/void vp10_fwd_txfm2d_4x4/, "const int16_t *input, int32_t *output, int stride, int tx_type, int bd"; specialize qw/vp10_fwd_txfm2d_4x4 sse4_1/; - add_proto qw/void vp10_fwd_txfm2d_8x8/, "const int16_t *input, int32_t *output, const int stride, int tx_type, const int bd"; + add_proto qw/void vp10_fwd_txfm2d_8x8/, "const int16_t *input, int32_t *output, int stride, int tx_type, int bd"; specialize qw/vp10_fwd_txfm2d_8x8 sse4_1/; - add_proto qw/void vp10_fwd_txfm2d_16x16/, "const int16_t *input, int32_t *output, const int stride, int tx_type, const int bd"; + add_proto qw/void vp10_fwd_txfm2d_16x16/, "const int16_t *input, int32_t *output, int stride, int tx_type, int bd"; specialize qw/vp10_fwd_txfm2d_16x16 sse4_1/; - add_proto qw/void vp10_fwd_txfm2d_32x32/, "const int16_t *input, int32_t *output, const int stride, int tx_type, const int bd"; + add_proto qw/void vp10_fwd_txfm2d_32x32/, "const int16_t *input, int32_t *output, int stride, int tx_type, int bd"; specialize qw/vp10_fwd_txfm2d_32x32 sse4_1/; - add_proto qw/void vp10_fwd_txfm2d_64x64/, "const int16_t *input, int32_t *output, const int stride, int tx_type, const int bd"; + add_proto qw/void vp10_fwd_txfm2d_64x64/, "const int16_t *input, int32_t *output, int stride, int tx_type, int bd"; specialize qw/vp10_fwd_txfm2d_64x64 sse4_1/; #inv txfm @@ -662,10 +662,10 @@ if (vpx_config("CONFIG_VP9_HIGHBITDEPTH") eq "yes") { add_proto qw/int64_t vp10_highbd_block_error/, "const tran_low_t *coeff, const tran_low_t *dqcoeff, intptr_t block_size, int64_t *ssz, int bd"; specialize qw/vp10_highbd_block_error sse2/; - add_proto qw/void vp10_highbd_quantize_fp/, "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_ptr, 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 int16_t *iscan, const int log_scale"; + add_proto qw/void vp10_highbd_quantize_fp/, "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_ptr, 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 int16_t *iscan, int log_scale"; specialize qw/vp10_highbd_quantize_fp/; - add_proto qw/void vp10_highbd_quantize_b/, "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_ptr, 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 int16_t *iscan, const int log_scale"; + add_proto qw/void vp10_highbd_quantize_b/, "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_ptr, 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 int16_t *iscan, int log_scale"; specialize qw/vp10_highbd_quantize_b/; # fdct functions diff --git a/vp10/encoder/quantize.c b/vp10/encoder/quantize.c index 3919fee46..2c61de5bd 100644 --- a/vp10/encoder/quantize.c +++ b/vp10/encoder/quantize.c @@ -186,7 +186,7 @@ void vp10_highbd_quantize_fp_c(const tran_low_t *coeff_ptr, const int16_t *dequant_ptr, uint16_t *eob_ptr, const int16_t *scan, - const int16_t *iscan, const int log_scale) { + const int16_t *iscan, int log_scale) { int i; int eob = -1; const int scale = 1 << log_scale; @@ -272,7 +272,7 @@ void vp10_highbd_quantize_b_c(const tran_low_t *coeff_ptr, intptr_t n_coeffs, tran_low_t *qcoeff_ptr, tran_low_t *dqcoeff_ptr, const int16_t *dequant_ptr, uint16_t *eob_ptr, const int16_t *scan, - const int16_t *iscan, const int log_scale) { + const int16_t *iscan, int log_scale) { int i, non_zero_count = (int)n_coeffs, eob = -1; int zbins[2] = {zbin_ptr[0], zbin_ptr[1]}; int round[2] = {round_ptr[0], round_ptr[1]}; diff --git a/vp10/encoder/x86/highbd_fwd_txfm_sse4.c b/vp10/encoder/x86/highbd_fwd_txfm_sse4.c index 23e08fea7..ce9089ed7 100644 --- a/vp10/encoder/x86/highbd_fwd_txfm_sse4.c +++ b/vp10/encoder/x86/highbd_fwd_txfm_sse4.c @@ -206,8 +206,7 @@ static void fadst4x4_sse4_1(__m128i *in, int bit) { } void vp10_fwd_txfm2d_4x4_sse4_1(const int16_t *input, int32_t *coeff, - const int input_stride, int tx_type, - const int bd) { + int input_stride, int tx_type, int bd) { __m128i in[4]; const TXFM_2D_CFG *cfg = NULL; @@ -916,7 +915,7 @@ static void fadst8x8_sse4_1(__m128i *in, __m128i *out, int bit) { } void vp10_fwd_txfm2d_8x8_sse4_1(const int16_t *input, int32_t *coeff, - const int stride, int tx_type, const int bd) { + int stride, int tx_type, int bd) { __m128i in[16], out[16]; const TXFM_2D_CFG *cfg = NULL;