diff options
author | Boyuan Yang <byang@debian.org> | 2021-11-07 08:50:20 -0500 |
---|---|---|
committer | Boyuan Yang <byang@debian.org> | 2021-11-07 08:50:20 -0500 |
commit | 513fcf1cd0dca1a6cbef9ff6e38e22237e75ba44 (patch) | |
tree | 249280ac94eb2b871de89cd1b166fff4ee00ab09 /src/dsp/loop_restoration_test.cc | |
parent | 3c21ceac2f6a5adfab07d3d458880561543d0a31 (diff) | |
parent | 320ef65362608ee1148c299d8d5d7618af34e470 (diff) | |
download | libgav1-513fcf1cd0dca1a6cbef9ff6e38e22237e75ba44.tar.gz libgav1-513fcf1cd0dca1a6cbef9ff6e38e22237e75ba44.tar.bz2 libgav1-513fcf1cd0dca1a6cbef9ff6e38e22237e75ba44.zip |
Update upstream source from tag 'upstream/0.17.0'
Update to upstream version '0.17.0'
with Debian dir 5b612b6a2d67788b0c85bac59e50edc1545bfd7e
Diffstat (limited to 'src/dsp/loop_restoration_test.cc')
-rw-r--r-- | src/dsp/loop_restoration_test.cc | 28 |
1 files changed, 25 insertions, 3 deletions
diff --git a/src/dsp/loop_restoration_test.cc b/src/dsp/loop_restoration_test.cc index 97a05d4..4c54bc6 100644 --- a/src/dsp/loop_restoration_test.cc +++ b/src/dsp/loop_restoration_test.cc @@ -83,6 +83,9 @@ class SelfGuidedFilterTest : public testing::TestWithParam<int>, } } else if (absl::StartsWith(test_case, "NEON/")) { LoopRestorationInit_NEON(); +#if LIBGAV1_MAX_BITDEPTH >= 10 + LoopRestorationInit10bpp_NEON(); +#endif } else { FAIL() << "Unrecognized architecture prefix in test case name: " << test_case; @@ -228,7 +231,11 @@ void SelfGuidedFilterTest<bitdepth, Pixel>::TestRandomValues(bool speed) { if (target_self_guided_filter_func_ == nullptr) return; constexpr int bd_index = (bitdepth == 8) ? 0 : 1; const int num_inputs = speed ? 1 : 5; - const int num_tests = speed ? 20000 : 1; +#if LIBGAV1_ENABLE_NEON + const int num_tests = speed ? 4000 : 1; +#else + const int num_tests = speed ? 10000 : 1; +#endif libvpx_test::ACMRandom rnd(libvpx_test::ACMRandom::DeterministicSeed()); const Pixel* const src = src_ + kOffset; Pixel* const dst = dst_ + kOffset; @@ -310,6 +317,10 @@ INSTANTIATE_TEST_SUITE_P(AVX2, SelfGuidedFilterTest10bpp, INSTANTIATE_TEST_SUITE_P(SSE41, SelfGuidedFilterTest10bpp, testing::ValuesIn(kUnitWidths)); #endif +#if LIBGAV1_ENABLE_NEON +INSTANTIATE_TEST_SUITE_P(NEON, SelfGuidedFilterTest10bpp, + testing::ValuesIn(kUnitWidths)); +#endif #endif // LIBGAV1_MAX_BITDEPTH >= 10 @@ -348,6 +359,9 @@ class WienerFilterTest : public testing::TestWithParam<int>, } } else if (absl::StartsWith(test_case, "NEON/")) { LoopRestorationInit_NEON(); +#if LIBGAV1_MAX_BITDEPTH >= 10 + LoopRestorationInit10bpp_NEON(); +#endif } else { FAIL() << "Unrecognized architecture prefix in test case name: " << test_case; @@ -477,7 +491,11 @@ void WienerFilterTest<bitdepth, Pixel>::TestRandomValues(bool speed) { "3c91bf1a34672cd40bf261c5820d3ec3"}}}; if (target_wiener_filter_func_ == nullptr) return; constexpr int bd_index = (bitdepth == 8) ? 0 : 1; - const int num_tests = speed ? 100000 : 1; +#if LIBGAV1_ENABLE_NEON + const int num_tests = speed ? 5000 : 1; +#else + const int num_tests = speed ? 10000 : 1; +#endif const Pixel* const src = src_ + kOffset; Pixel* const dst = dst_ + kOffset; for (const auto vertical_order : kWienerOrders) { @@ -545,7 +563,7 @@ void WienerFilterTest<bitdepth, Pixel>::TestCompare2C() { kStride, unit_width_, unit_height_, &restoration_buffer_, tmp); if (!test_utils::CompareBlocks(dst, tmp, unit_width_, unit_height_, - kStride, kStride, false, false)) { + kStride, kStride, false, true)) { ADD_FAILURE() << "Mismatch -- wiener taps min/max"; } } @@ -608,6 +626,10 @@ INSTANTIATE_TEST_SUITE_P(AVX2, WienerFilterTest10bpp, INSTANTIATE_TEST_SUITE_P(SSE41, WienerFilterTest10bpp, testing::ValuesIn(kUnitWidths)); #endif +#if LIBGAV1_ENABLE_NEON +INSTANTIATE_TEST_SUITE_P(NEON, WienerFilterTest10bpp, + testing::ValuesIn(kUnitWidths)); +#endif #endif // LIBGAV1_MAX_BITDEPTH >= 10 |