fwd_txfm: conditionally include aom_{highbd_,}fdct8x8_c
this is only used with CONFIG_INTERNAL_STATS via psnr-hvs.
Bug: aomedia:3416
Change-Id: I250ac8596cd96c0b9fa4aca1f967c297b9da98f2
diff --git a/aom_dsp/aom_dsp_rtcd_defs.pl b/aom_dsp/aom_dsp_rtcd_defs.pl
index baea019..ff8b48f 100755
--- a/aom_dsp/aom_dsp_rtcd_defs.pl
+++ b/aom_dsp/aom_dsp_rtcd_defs.pl
@@ -607,14 +607,16 @@
add_proto qw/void aom_fdct4x4_lp/, "const int16_t *input, int16_t *output, int stride";
specialize qw/aom_fdct4x4_lp neon sse2/;
- # 8x8 DCT transform for psnr-hvs. Unlike other transforms isn't compatible
- # with av1 scan orders, because it does two transposes.
- add_proto qw/void aom_fdct8x8/, "const int16_t *input, tran_low_t *output, int stride";
- specialize qw/aom_fdct8x8 neon sse2/, "$ssse3_x86_64";
- # High bit depth
- if (aom_config("CONFIG_AV1_HIGHBITDEPTH") eq "yes") {
- add_proto qw/void aom_highbd_fdct8x8/, "const int16_t *input, tran_low_t *output, int stride";
- specialize qw/aom_highbd_fdct8x8 sse2/;
+ if (aom_config("CONFIG_INTERNAL_STATS") eq "yes"){
+ # 8x8 DCT transform for psnr-hvs. Unlike other transforms isn't compatible
+ # with av1 scan orders, because it does two transposes.
+ add_proto qw/void aom_fdct8x8/, "const int16_t *input, tran_low_t *output, int stride";
+ specialize qw/aom_fdct8x8 neon sse2/, "$ssse3_x86_64";
+ # High bit depth
+ if (aom_config("CONFIG_AV1_HIGHBITDEPTH") eq "yes") {
+ add_proto qw/void aom_highbd_fdct8x8/, "const int16_t *input, tran_low_t *output, int stride";
+ specialize qw/aom_highbd_fdct8x8 sse2/;
+ }
}
# FFT/IFFT (float) only used for denoising (and noise power spectral density estimation)
add_proto qw/void aom_fft2x2_float/, "const float *input, float *temp, float *output";
diff --git a/aom_dsp/fwd_txfm.c b/aom_dsp/fwd_txfm.c
index fbf9ead..5503501 100644
--- a/aom_dsp/fwd_txfm.c
+++ b/aom_dsp/fwd_txfm.c
@@ -151,6 +151,7 @@
}
}
+#if CONFIG_INTERNAL_STATS
void aom_fdct8x8_c(const int16_t *input, tran_low_t *final_output, int stride) {
int i, j;
tran_low_t intermediate[64];
@@ -234,8 +235,9 @@
for (j = 0; j < 8; ++j) final_output[j + i * 8] /= 2;
}
}
+#endif // CONFIG_INTERNAL_STATS
-#if CONFIG_AV1_HIGHBITDEPTH
+#if CONFIG_AV1_HIGHBITDEPTH && CONFIG_INTERNAL_STATS
void aom_highbd_fdct8x8_c(const int16_t *input, tran_low_t *final_output,
int stride) {
aom_fdct8x8_c(input, final_output, stride);
diff --git a/aom_dsp/x86/fwd_txfm_impl_sse2.h b/aom_dsp/x86/fwd_txfm_impl_sse2.h
index df1e229..7ee8ba3 100644
--- a/aom_dsp/x86/fwd_txfm_impl_sse2.h
+++ b/aom_dsp/x86/fwd_txfm_impl_sse2.h
@@ -213,6 +213,7 @@
_mm_storeu_si128((__m128i *)(output + 2 * 4), in1);
}
+#if CONFIG_INTERNAL_STATS
void FDCT8x8_2D(const int16_t *input, tran_low_t *output, int stride) {
int pass;
// Constants
@@ -522,6 +523,7 @@
store_output(&in7, (output + 7 * 8));
}
}
+#endif // CONFIG_INTERNAL_STATS
#undef ADD_EPI16
#undef SUB_EPI16