mirror of
https://github.com/intel/compute-runtime.git
synced 2025-12-31 12:11:31 +08:00
performance: move host/device memUsmAllocPool init to platform/context init
Related-To: NEO-16059 Signed-off-by: Aleksander Czerwionka <aleksander.czerwionka@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
6ec9ebd7a6
commit
f0f869ed42
@@ -3977,10 +3977,7 @@ CL_API_ENTRY void *CL_API_CALL clHostMemAllocINTEL(
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
auto platform = neoContext->getDevice(0u)->getPlatform();
|
||||
platform->initializeHostUsmAllocationPool();
|
||||
|
||||
auto allocationFromPool = platform->getHostMemAllocPool().createUnifiedMemoryAllocation(size, unifiedMemoryProperties);
|
||||
auto allocationFromPool = neoContext->getDevice(0u)->getPlatform()->getHostMemAllocPool().createUnifiedMemoryAllocation(size, unifiedMemoryProperties);
|
||||
if (allocationFromPool) {
|
||||
TRACING_EXIT(ClHostMemAllocINTEL, &allocationFromPool);
|
||||
return allocationFromPool;
|
||||
@@ -4042,8 +4039,6 @@ CL_API_ENTRY void *CL_API_CALL clDeviceMemAllocINTEL(
|
||||
|
||||
unifiedMemoryProperties.device = &neoDevice->getDevice();
|
||||
|
||||
neoContext->initializeDeviceUsmAllocationPool();
|
||||
|
||||
auto allocationFromPool = neoContext->getDeviceMemAllocPool().createUnifiedMemoryAllocation(size, unifiedMemoryProperties);
|
||||
if (allocationFromPool) {
|
||||
TRACING_EXIT(ClDeviceMemAllocINTEL, &allocationFromPool);
|
||||
|
||||
Reference in New Issue
Block a user