ocl: restore clFinish() in unmap() for AMD devices
This reverts commit 7d91b8efcd053304e5b0fb5afff06e151b2d4096.
This commit is contained in:
parent
e40567eaee
commit
579a7fff6d
@ -3979,6 +3979,11 @@ public:
|
|||||||
u->markDeviceMemMapped(false);
|
u->markDeviceMemMapped(false);
|
||||||
CV_Assert( (retval = clEnqueueUnmapMemObject(q,
|
CV_Assert( (retval = clEnqueueUnmapMemObject(q,
|
||||||
(cl_mem)u->handle, u->data, 0, 0, 0)) == CL_SUCCESS );
|
(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;
|
u->data = 0;
|
||||||
}
|
}
|
||||||
else if( u->copyOnMap() && u->deviceCopyObsolete() )
|
else if( u->copyOnMap() && u->deviceCopyObsolete() )
|
||||||
|
Loading…
x
Reference in New Issue
Block a user