| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (c) 2012 The WebM project authors. All Rights Reserved. | 2 * Copyright (c) 2012 The WebM project authors. All Rights Reserved. |
| 3 * | 3 * |
| 4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
| 5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
| 6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
| 7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
| 8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
| 9 */ | 9 */ |
| 10 | 10 |
| 11 #include <math.h> | 11 #include <math.h> |
| 12 #include <stdlib.h> | 12 #include <stdlib.h> |
| 13 #include <string.h> | 13 #include <string.h> |
| 14 #include "test/acm_random.h" | 14 #include "test/acm_random.h" |
| 15 #include "test/clear_system_state.h" |
| 15 #include "test/register_state_check.h" | 16 #include "test/register_state_check.h" |
| 16 #include "test/util.h" | 17 #include "test/util.h" |
| 17 #include "third_party/googletest/src/include/gtest/gtest.h" | 18 #include "third_party/googletest/src/include/gtest/gtest.h" |
| 18 extern "C" { | 19 extern "C" { |
| 19 #include "./vpx_config.h" | 20 #include "./vpx_config.h" |
| 20 #include "./vp8_rtcd.h" | 21 #include "./vp8_rtcd.h" |
| 21 #include "vpx/vpx_integer.h" | 22 #include "vpx/vpx_integer.h" |
| 22 #include "vpx_mem/vpx_mem.h" | 23 #include "vpx_mem/vpx_mem.h" |
| 23 } | 24 } |
| 24 | 25 |
| (...skipping 16 matching lines...) Expand all Loading... |
| 41 | 42 |
| 42 static void TearDownTestCase() { | 43 static void TearDownTestCase() { |
| 43 vpx_free(src_); | 44 vpx_free(src_); |
| 44 src_ = NULL; | 45 src_ = NULL; |
| 45 vpx_free(dst_); | 46 vpx_free(dst_); |
| 46 dst_ = NULL; | 47 dst_ = NULL; |
| 47 vpx_free(dst_c_); | 48 vpx_free(dst_c_); |
| 48 dst_c_ = NULL; | 49 dst_c_ = NULL; |
| 49 } | 50 } |
| 50 | 51 |
| 52 virtual void TearDown() { |
| 53 libvpx_test::ClearSystemState(); |
| 54 } |
| 55 |
| 51 protected: | 56 protected: |
| 52 // Make test arrays big enough for 16x16 functions. Six-tap filters | 57 // Make test arrays big enough for 16x16 functions. Six-tap filters |
| 53 // need 5 extra pixels outside of the macroblock. | 58 // need 5 extra pixels outside of the macroblock. |
| 54 static const int kSrcStride = 21; | 59 static const int kSrcStride = 21; |
| 55 static const int kDstStride = 16; | 60 static const int kDstStride = 16; |
| 56 static const int kDataAlignment = 16; | 61 static const int kDataAlignment = 16; |
| 57 static const int kSrcSize = kSrcStride * kSrcStride + 1; | 62 static const int kSrcSize = kSrcStride * kSrcStride + 1; |
| 58 static const int kDstSize = kDstStride * kDstStride; | 63 static const int kDstSize = kDstStride * kDstStride; |
| 59 | 64 |
| 60 virtual void SetUp() { | 65 virtual void SetUp() { |
| (...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 215 const sixtap_predict_fn_t sixtap_8x4_ssse3 = vp8_sixtap_predict8x4_ssse3; | 220 const sixtap_predict_fn_t sixtap_8x4_ssse3 = vp8_sixtap_predict8x4_ssse3; |
| 216 const sixtap_predict_fn_t sixtap_4x4_ssse3 = vp8_sixtap_predict4x4_ssse3; | 221 const sixtap_predict_fn_t sixtap_4x4_ssse3 = vp8_sixtap_predict4x4_ssse3; |
| 217 INSTANTIATE_TEST_CASE_P( | 222 INSTANTIATE_TEST_CASE_P( |
| 218 SSSE3, SixtapPredictTest, ::testing::Values( | 223 SSSE3, SixtapPredictTest, ::testing::Values( |
| 219 make_tuple(16, 16, sixtap_16x16_ssse3), | 224 make_tuple(16, 16, sixtap_16x16_ssse3), |
| 220 make_tuple(8, 8, sixtap_8x8_ssse3), | 225 make_tuple(8, 8, sixtap_8x8_ssse3), |
| 221 make_tuple(8, 4, sixtap_8x4_ssse3), | 226 make_tuple(8, 4, sixtap_8x4_ssse3), |
| 222 make_tuple(4, 4, sixtap_4x4_ssse3))); | 227 make_tuple(4, 4, sixtap_4x4_ssse3))); |
| 223 #endif | 228 #endif |
| 224 } // namespace | 229 } // namespace |
| OLD | NEW |