Initial implementation for creating buffer with ext memory for OpenCl

Related-To: NEO-6757

Signed-off-by: Baj, Tomasz <tomasz.baj@intel.com>
This commit is contained in:
Baj, Tomasz
2022-04-26 10:25:41 +00:00
committed by Compute-Runtime-Automation
parent 28317e7062
commit 2a0c395db5
14 changed files with 383 additions and 5 deletions

View File

@@ -0,0 +1,18 @@
/*
* Copyright (C) 2022 Intel Corporation
*
* SPDX-License-Identifier: MIT
*
*/
#include "opencl/source/mem_obj/buffer.h"
namespace NEO {
bool Buffer::validateHandleType(MemoryProperties &memoryProperties, UnifiedSharingMemoryDescription &extMem) {
if (memoryProperties.handleType == static_cast<uint64_t>(UnifiedSharingHandleType::LinuxFd)) {
extMem.type = UnifiedSharingHandleType::LinuxFd;
return true;
}
return false;
}
} // namespace NEO