]> granicus.if.org Git - libvpx/commitdiff
vp8: adds multithread testing.
authorJim Bankoski <jimbankoski@google.com>
Fri, 9 Dec 2016 23:05:59 +0000 (15:05 -0800)
committerJim Bankoski <jimbankoski@google.com>
Fri, 9 Dec 2016 23:05:59 +0000 (15:05 -0800)
The test is disabled because of TSAN errors until we resolve
BUG=webm:851

Change-Id: I0b21c8d815bc1ea365da024b1e2ee5e1fc5715c2

test/test_vector_test.cc

index 6d43157404122e0bc5723d1b9e9c2c731a34e67e..424c17d9d5b6e139fda8098b8c150b20d3746df8 100644 (file)
@@ -145,17 +145,31 @@ TEST_P(TestVectorTest, MD5Match) {
   ASSERT_NO_FATAL_FAILURE(RunLoop(video.get(), cfg));
 }
 
-// Test VP8 decode in serial mode with single thread.
+// Test VP8 decode in serial mode with single thread and with 8 threads.
 // NOTE: VP8 only support serial mode.
 #if CONFIG_VP8_DECODER
 VP8_INSTANTIATE_TEST_CASE(
     TestVectorTest,
     ::testing::Combine(
         ::testing::Values(0),  // Serial Mode.
-        ::testing::Values(1),  // Single thread.
+        ::testing::Values(1),  // Single thread and 8 threads.
         ::testing::ValuesIn(libvpx_test::kVP8TestVectors,
                             libvpx_test::kVP8TestVectors +
                                 libvpx_test::kNumVP8TestVectors)));
+
+// Test VP8 decode in with different numbers of threads.
+INSTANTIATE_TEST_CASE_P(
+    DISABLED_VP8MultiThreaded, TestVectorTest,
+    ::testing::Combine(
+        ::testing::Values(
+            static_cast<const libvpx_test::CodecFactory *>(&libvpx_test::kVP8)),
+        ::testing::Combine(
+            ::testing::Values(0),    // Serial Mode.
+            ::testing::Range(1, 8),  // With 1 ~ 8 threads.
+            ::testing::ValuesIn(libvpx_test::kVP8TestVectors,
+                                libvpx_test::kVP8TestVectors +
+                                    libvpx_test::kNumVP8TestVectors))));
+
 #endif  // CONFIG_VP8_DECODER
 
 // Test VP9 decode in serial mode with single thread.