Commit 3316e583 authored by Alexander Alekhin's avatar Alexander Alekhin

more test loops (and disable tests - tests pass but require a lot of time)

parent 8293ed7f
...@@ -1029,14 +1029,14 @@ TEST(UMat, map_unmap_counting) ...@@ -1029,14 +1029,14 @@ TEST(UMat, map_unmap_counting)
///////////// oclCleanupCallback threadsafe check (#5062) ///////////////////// ///////////// oclCleanupCallback threadsafe check (#5062) /////////////////////
// Case 1: reuse of old src Mat in OCL pipe. Hard to catch! // Case 1: reuse of old src Mat in OCL pipe. Hard to catch!
OCL_TEST(UMat, OCL_ThreadSafe_CleanupCallback_1_VeryLongTest) OCL_TEST(UMat, DISABLED_OCL_ThreadSafe_CleanupCallback_1_VeryLongTest)
{ {
if (!cv::ocl::useOpenCL()) if (!cv::ocl::useOpenCL())
{ {
std::cout << "OpenCL is not enabled. Skip test" << std::endl; std::cout << "OpenCL is not enabled. Skip test" << std::endl;
return; return;
} }
for (int j = 0; j < test_loop_times; j++) for (int j = 0; j < 100; j++)
{ {
const Size srcSize(320, 240); const Size srcSize(320, 240);
const int type = CV_8UC1; const int type = CV_8UC1;
...@@ -1060,18 +1060,19 @@ OCL_TEST(UMat, OCL_ThreadSafe_CleanupCallback_1_VeryLongTest) ...@@ -1060,18 +1060,19 @@ OCL_TEST(UMat, OCL_ThreadSafe_CleanupCallback_1_VeryLongTest)
} }
EXPECT_MAT_NEAR(dst_ref, dst, 1); EXPECT_MAT_NEAR(dst_ref, dst, 1);
printf(".\n"); fflush(stdout);
} }
} }
// Case 2: concurent deallocation of UMatData between UMat and Mat deallocators. Hard to catch! // Case 2: concurent deallocation of UMatData between UMat and Mat deallocators. Hard to catch!
OCL_TEST(UMat, OCL_ThreadSafe_CleanupCallback_2_VeryLongTest) OCL_TEST(UMat, DISABLED_OCL_ThreadSafe_CleanupCallback_2_VeryLongTest)
{ {
if (!cv::ocl::useOpenCL()) if (!cv::ocl::useOpenCL())
{ {
std::cout << "OpenCL is not enabled. Skip test" << std::endl; std::cout << "OpenCL is not enabled. Skip test" << std::endl;
return; return;
} }
for (int j = 0; j < test_loop_times; j++) for (int j = 0; j < 100; j++)
{ {
const Size srcSize(320, 240); const Size srcSize(320, 240);
const int type = CV_8UC1; const int type = CV_8UC1;
...@@ -1090,6 +1091,7 @@ OCL_TEST(UMat, OCL_ThreadSafe_CleanupCallback_2_VeryLongTest) ...@@ -1090,6 +1091,7 @@ OCL_TEST(UMat, OCL_ThreadSafe_CleanupCallback_2_VeryLongTest)
} }
::cv::ocl::finish(); // force kernel to complete to start cleanup sooner ::cv::ocl::finish(); // force kernel to complete to start cleanup sooner
} }
printf(".\n"); fflush(stdout);
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment