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 |
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
75 void fdct8x8_ref(const int16_t *in, tran_low_t *out, int stride, int tx_type) { | 75 void fdct8x8_ref(const int16_t *in, tran_low_t *out, int stride, int tx_type) { |
76 vp9_fdct8x8_c(in, out, stride); | 76 vp9_fdct8x8_c(in, out, stride); |
77 } | 77 } |
78 | 78 |
79 void fht8x8_ref(const int16_t *in, tran_low_t *out, int stride, int tx_type) { | 79 void fht8x8_ref(const int16_t *in, tran_low_t *out, int stride, int tx_type) { |
80 vp9_fht8x8_c(in, out, stride, tx_type); | 80 vp9_fht8x8_c(in, out, stride, tx_type); |
81 } | 81 } |
82 | 82 |
83 #if CONFIG_VP9_HIGHBITDEPTH | 83 #if CONFIG_VP9_HIGHBITDEPTH |
84 void idct8x8_10(const tran_low_t *in, uint8_t *out, int stride) { | 84 void idct8x8_10(const tran_low_t *in, uint8_t *out, int stride) { |
85 vp9_high_idct8x8_64_add_c(in, out, stride, 10); | 85 vp9_highbd_idct8x8_64_add_c(in, out, stride, 10); |
86 } | 86 } |
87 | 87 |
88 void idct8x8_12(const tran_low_t *in, uint8_t *out, int stride) { | 88 void idct8x8_12(const tran_low_t *in, uint8_t *out, int stride) { |
89 vp9_high_idct8x8_64_add_c(in, out, stride, 12); | 89 vp9_highbd_idct8x8_64_add_c(in, out, stride, 12); |
90 } | 90 } |
91 | 91 |
92 void iht8x8_10(const tran_low_t *in, uint8_t *out, int stride, int tx_type) { | 92 void iht8x8_10(const tran_low_t *in, uint8_t *out, int stride, int tx_type) { |
93 vp9_high_iht8x8_64_add_c(in, out, stride, tx_type, 10); | 93 vp9_highbd_iht8x8_64_add_c(in, out, stride, tx_type, 10); |
94 } | 94 } |
95 | 95 |
96 void iht8x8_12(const tran_low_t *in, uint8_t *out, int stride, int tx_type) { | 96 void iht8x8_12(const tran_low_t *in, uint8_t *out, int stride, int tx_type) { |
97 vp9_high_iht8x8_64_add_c(in, out, stride, tx_type, 12); | 97 vp9_highbd_iht8x8_64_add_c(in, out, stride, tx_type, 12); |
98 } | 98 } |
99 #endif | 99 #endif |
100 | 100 |
101 class FwdTrans8x8TestBase { | 101 class FwdTrans8x8TestBase { |
102 public: | 102 public: |
103 virtual ~FwdTrans8x8TestBase() {} | 103 virtual ~FwdTrans8x8TestBase() {} |
104 | 104 |
105 protected: | 105 protected: |
106 virtual void RunFwdTxfm(int16_t *in, tran_low_t *out, int stride) = 0; | 106 virtual void RunFwdTxfm(int16_t *in, tran_low_t *out, int stride) = 0; |
107 virtual void RunInvTxfm(tran_low_t *out, uint8_t *dst, int stride) = 0; | 107 virtual void RunInvTxfm(tran_low_t *out, uint8_t *dst, int stride) = 0; |
(...skipping 417 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
525 TEST_P(FwdTrans8x8HT, ExtremalCheck) { | 525 TEST_P(FwdTrans8x8HT, ExtremalCheck) { |
526 RunExtremalCheck(); | 526 RunExtremalCheck(); |
527 } | 527 } |
528 | 528 |
529 using std::tr1::make_tuple; | 529 using std::tr1::make_tuple; |
530 | 530 |
531 #if CONFIG_VP9_HIGHBITDEPTH | 531 #if CONFIG_VP9_HIGHBITDEPTH |
532 INSTANTIATE_TEST_CASE_P( | 532 INSTANTIATE_TEST_CASE_P( |
533 C, FwdTrans8x8DCT, | 533 C, FwdTrans8x8DCT, |
534 ::testing::Values( | 534 ::testing::Values( |
535 make_tuple(&vp9_high_fdct8x8_c, &idct8x8_10, 0, VPX_BITS_10), | 535 make_tuple(&vp9_highbd_fdct8x8_c, &idct8x8_10, 0, VPX_BITS_10), |
536 make_tuple(&vp9_high_fdct8x8_c, &idct8x8_12, 0, VPX_BITS_12), | 536 make_tuple(&vp9_highbd_fdct8x8_c, &idct8x8_12, 0, VPX_BITS_12), |
537 make_tuple(&vp9_fdct8x8_c, &vp9_idct8x8_64_add_c, 0, VPX_BITS_8))); | 537 make_tuple(&vp9_fdct8x8_c, &vp9_idct8x8_64_add_c, 0, VPX_BITS_8))); |
538 #else | 538 #else |
539 INSTANTIATE_TEST_CASE_P( | 539 INSTANTIATE_TEST_CASE_P( |
540 C, FwdTrans8x8DCT, | 540 C, FwdTrans8x8DCT, |
541 ::testing::Values( | 541 ::testing::Values( |
542 make_tuple(&vp9_fdct8x8_c, &vp9_idct8x8_64_add_c, 0, VPX_BITS_8))); | 542 make_tuple(&vp9_fdct8x8_c, &vp9_idct8x8_64_add_c, 0, VPX_BITS_8))); |
543 #endif | 543 #endif |
544 | 544 |
545 #if CONFIG_VP9_HIGHBITDEPTH | 545 #if CONFIG_VP9_HIGHBITDEPTH |
546 INSTANTIATE_TEST_CASE_P( | 546 INSTANTIATE_TEST_CASE_P( |
547 C, FwdTrans8x8HT, | 547 C, FwdTrans8x8HT, |
548 ::testing::Values( | 548 ::testing::Values( |
549 make_tuple(&vp9_high_fht8x8_c, &iht8x8_10, 0, VPX_BITS_10), | 549 make_tuple(&vp9_highbd_fht8x8_c, &iht8x8_10, 0, VPX_BITS_10), |
550 make_tuple(&vp9_high_fht8x8_c, &iht8x8_10, 1, VPX_BITS_10), | 550 make_tuple(&vp9_highbd_fht8x8_c, &iht8x8_10, 1, VPX_BITS_10), |
551 make_tuple(&vp9_high_fht8x8_c, &iht8x8_10, 2, VPX_BITS_10), | 551 make_tuple(&vp9_highbd_fht8x8_c, &iht8x8_10, 2, VPX_BITS_10), |
552 make_tuple(&vp9_high_fht8x8_c, &iht8x8_10, 3, VPX_BITS_10), | 552 make_tuple(&vp9_highbd_fht8x8_c, &iht8x8_10, 3, VPX_BITS_10), |
553 make_tuple(&vp9_high_fht8x8_c, &iht8x8_12, 0, VPX_BITS_12), | 553 make_tuple(&vp9_highbd_fht8x8_c, &iht8x8_12, 0, VPX_BITS_12), |
554 make_tuple(&vp9_high_fht8x8_c, &iht8x8_12, 1, VPX_BITS_12), | 554 make_tuple(&vp9_highbd_fht8x8_c, &iht8x8_12, 1, VPX_BITS_12), |
555 make_tuple(&vp9_high_fht8x8_c, &iht8x8_12, 2, VPX_BITS_12), | 555 make_tuple(&vp9_highbd_fht8x8_c, &iht8x8_12, 2, VPX_BITS_12), |
556 make_tuple(&vp9_high_fht8x8_c, &iht8x8_12, 3, VPX_BITS_12), | 556 make_tuple(&vp9_highbd_fht8x8_c, &iht8x8_12, 3, VPX_BITS_12), |
557 make_tuple(&vp9_fht8x8_c, &vp9_iht8x8_64_add_c, 0, VPX_BITS_8), | 557 make_tuple(&vp9_fht8x8_c, &vp9_iht8x8_64_add_c, 0, VPX_BITS_8), |
558 make_tuple(&vp9_fht8x8_c, &vp9_iht8x8_64_add_c, 1, VPX_BITS_8), | 558 make_tuple(&vp9_fht8x8_c, &vp9_iht8x8_64_add_c, 1, VPX_BITS_8), |
559 make_tuple(&vp9_fht8x8_c, &vp9_iht8x8_64_add_c, 2, VPX_BITS_8), | 559 make_tuple(&vp9_fht8x8_c, &vp9_iht8x8_64_add_c, 2, VPX_BITS_8), |
560 make_tuple(&vp9_fht8x8_c, &vp9_iht8x8_64_add_c, 3, VPX_BITS_8))); | 560 make_tuple(&vp9_fht8x8_c, &vp9_iht8x8_64_add_c, 3, VPX_BITS_8))); |
561 #else | 561 #else |
562 INSTANTIATE_TEST_CASE_P( | 562 INSTANTIATE_TEST_CASE_P( |
563 C, FwdTrans8x8HT, | 563 C, FwdTrans8x8HT, |
564 ::testing::Values( | 564 ::testing::Values( |
565 make_tuple(&vp9_fht8x8_c, &vp9_iht8x8_64_add_c, 0, VPX_BITS_8), | 565 make_tuple(&vp9_fht8x8_c, &vp9_iht8x8_64_add_c, 0, VPX_BITS_8), |
566 make_tuple(&vp9_fht8x8_c, &vp9_iht8x8_64_add_c, 1, VPX_BITS_8), | 566 make_tuple(&vp9_fht8x8_c, &vp9_iht8x8_64_add_c, 1, VPX_BITS_8), |
567 make_tuple(&vp9_fht8x8_c, &vp9_iht8x8_64_add_c, 2, VPX_BITS_8), | 567 make_tuple(&vp9_fht8x8_c, &vp9_iht8x8_64_add_c, 2, VPX_BITS_8), |
568 make_tuple(&vp9_fht8x8_c, &vp9_iht8x8_64_add_c, 3, VPX_BITS_8))); | 568 make_tuple(&vp9_fht8x8_c, &vp9_iht8x8_64_add_c, 3, VPX_BITS_8))); |
569 #endif | 569 #endif |
570 | 570 |
571 #if HAVE_NEON_ASM && !CONFIG_VP9_HIGHBITDEPTH | 571 #if HAVE_NEON_ASM && !CONFIG_VP9_HIGHBITDEPTH && !CONFIG_EMULATE_HARDWARE |
572 INSTANTIATE_TEST_CASE_P( | 572 INSTANTIATE_TEST_CASE_P( |
573 NEON, FwdTrans8x8DCT, | 573 NEON, FwdTrans8x8DCT, |
574 ::testing::Values( | 574 ::testing::Values( |
575 make_tuple(&vp9_fdct8x8_neon, &vp9_idct8x8_64_add_neon, 0, | 575 make_tuple(&vp9_fdct8x8_neon, &vp9_idct8x8_64_add_neon, 0, |
576 VPX_BITS_8))); | 576 VPX_BITS_8))); |
577 INSTANTIATE_TEST_CASE_P( | 577 INSTANTIATE_TEST_CASE_P( |
578 DISABLED_NEON, FwdTrans8x8HT, | 578 DISABLED_NEON, FwdTrans8x8HT, |
579 ::testing::Values( | 579 ::testing::Values( |
580 make_tuple(&vp9_fht8x8_c, &vp9_iht8x8_64_add_neon, 0, VPX_BITS_8), | 580 make_tuple(&vp9_fht8x8_c, &vp9_iht8x8_64_add_neon, 0, VPX_BITS_8), |
581 make_tuple(&vp9_fht8x8_c, &vp9_iht8x8_64_add_neon, 1, VPX_BITS_8), | 581 make_tuple(&vp9_fht8x8_c, &vp9_iht8x8_64_add_neon, 1, VPX_BITS_8), |
582 make_tuple(&vp9_fht8x8_c, &vp9_iht8x8_64_add_neon, 2, VPX_BITS_8), | 582 make_tuple(&vp9_fht8x8_c, &vp9_iht8x8_64_add_neon, 2, VPX_BITS_8), |
583 make_tuple(&vp9_fht8x8_c, &vp9_iht8x8_64_add_neon, 3, VPX_BITS_8))); | 583 make_tuple(&vp9_fht8x8_c, &vp9_iht8x8_64_add_neon, 3, VPX_BITS_8))); |
584 #endif | 584 #endif |
585 | 585 |
586 #if HAVE_SSE2 && !CONFIG_VP9_HIGHBITDEPTH | 586 #if HAVE_SSE2 && !CONFIG_VP9_HIGHBITDEPTH && !CONFIG_EMULATE_HARDWARE |
587 INSTANTIATE_TEST_CASE_P( | 587 INSTANTIATE_TEST_CASE_P( |
588 SSE2, FwdTrans8x8DCT, | 588 SSE2, FwdTrans8x8DCT, |
589 ::testing::Values( | 589 ::testing::Values( |
590 make_tuple(&vp9_fdct8x8_sse2, &vp9_idct8x8_64_add_sse2, 0, | 590 make_tuple(&vp9_fdct8x8_sse2, &vp9_idct8x8_64_add_sse2, 0, |
591 VPX_BITS_8))); | 591 VPX_BITS_8))); |
592 INSTANTIATE_TEST_CASE_P( | 592 INSTANTIATE_TEST_CASE_P( |
593 SSE2, FwdTrans8x8HT, | 593 SSE2, FwdTrans8x8HT, |
594 ::testing::Values( | 594 ::testing::Values( |
595 make_tuple(&vp9_fht8x8_sse2, &vp9_iht8x8_64_add_sse2, 0, VPX_BITS_8), | 595 make_tuple(&vp9_fht8x8_sse2, &vp9_iht8x8_64_add_sse2, 0, VPX_BITS_8), |
596 make_tuple(&vp9_fht8x8_sse2, &vp9_iht8x8_64_add_sse2, 1, VPX_BITS_8), | 596 make_tuple(&vp9_fht8x8_sse2, &vp9_iht8x8_64_add_sse2, 1, VPX_BITS_8), |
597 make_tuple(&vp9_fht8x8_sse2, &vp9_iht8x8_64_add_sse2, 2, VPX_BITS_8), | 597 make_tuple(&vp9_fht8x8_sse2, &vp9_iht8x8_64_add_sse2, 2, VPX_BITS_8), |
598 make_tuple(&vp9_fht8x8_sse2, &vp9_iht8x8_64_add_sse2, 3, VPX_BITS_8))); | 598 make_tuple(&vp9_fht8x8_sse2, &vp9_iht8x8_64_add_sse2, 3, VPX_BITS_8))); |
599 #endif | 599 #endif |
600 | 600 |
601 #if HAVE_SSSE3 && ARCH_X86_64 && !CONFIG_VP9_HIGHBITDEPTH | 601 #if HAVE_SSSE3 && ARCH_X86_64 && !CONFIG_VP9_HIGHBITDEPTH && \ |
| 602 !CONFIG_EMULATE_HARDWARE |
602 INSTANTIATE_TEST_CASE_P( | 603 INSTANTIATE_TEST_CASE_P( |
603 SSSE3, FwdTrans8x8DCT, | 604 SSSE3, FwdTrans8x8DCT, |
604 ::testing::Values( | 605 ::testing::Values( |
605 make_tuple(&vp9_fdct8x8_ssse3, &vp9_idct8x8_64_add_ssse3, 0, | 606 make_tuple(&vp9_fdct8x8_ssse3, &vp9_idct8x8_64_add_ssse3, 0, |
606 VPX_BITS_8))); | 607 VPX_BITS_8))); |
607 #endif | 608 #endif |
608 } // namespace | 609 } // namespace |
OLD | NEW |