1
0
mirror of https://github.com/opencv/opencv.git synced 2026-07-30 07:43:03 +04:00

Merge pull request #3368 from alalek:amd_clfinish

This commit is contained in:
Alexander Alekhin
2014-10-24 12:58:21 +00:00
+5
View File
@@ -3979,6 +3979,11 @@ public:
u->markDeviceMemMapped(false);
CV_Assert( (retval = clEnqueueUnmapMemObject(q,
(cl_mem)u->handle, u->data, 0, 0, 0)) == CL_SUCCESS );
if (Device::getDefault().isAMD())
{
// required for multithreaded applications (see stitching test)
CV_OclDbgAssert(clFinish(q) == CL_SUCCESS);
}
u->data = 0;
}
else if( u->copyOnMap() && u->deviceCopyObsolete() )