P4 to Git Change 1095076 by rili@rili_opencl_stg on 2014/11/07 16:25:17

EPR #408185 - Use pinned memory if directaccess is true and remoteAlloc is used.

Affected files ...

... //depot/stg/opencl/drivers/opencl/runtime/device/gpu/gpudevice.cpp#478 edit


[ROCm/clr commit: c24b46e708]
Este commit está contenido en:
foreman
2014-11-07 16:37:32 -05:00
padre 9c323d76cc
commit f02e1e3ed8
@@ -1565,7 +1565,8 @@ Device::createBuffer(
}
else if (directAccess || (type == Resource::Remote)) {
// Check for system memory allocations
if (owner.getMemFlags() & (CL_MEM_ALLOC_HOST_PTR | CL_MEM_USE_HOST_PTR)) {
if ((owner.getMemFlags() & (CL_MEM_ALLOC_HOST_PTR | CL_MEM_USE_HOST_PTR))
|| (settings().remoteAlloc_)) {
// Allocate remote memory if AHP allocation and context has just 1 device
if ((owner.getMemFlags() & CL_MEM_ALLOC_HOST_PTR) &&
(owner.getContext().devices().size() == 1)) {