GraphicsAllocation constructor accepts allocationType and memoryPool.

Change-Id: I5044ed26ba0cb0fc9ca7077595f5ab56353ab58c
This commit is contained in:
Piotr Fusik
2019-02-26 11:37:51 +01:00
committed by sys_ocldev
parent 798137e4bb
commit d79f1afdc2
18 changed files with 102 additions and 87 deletions

View File

@@ -23,19 +23,24 @@ bool GraphicsAllocation::isL3Capable() {
}
return false;
}
GraphicsAllocation::GraphicsAllocation(void *cpuPtrIn, uint64_t gpuAddress, uint64_t baseAddress,
size_t sizeIn, bool multiOsContextCapable)
GraphicsAllocation::GraphicsAllocation(AllocationType allocationType, void *cpuPtrIn, uint64_t gpuAddress, uint64_t baseAddress,
size_t sizeIn, MemoryPool::Type pool, bool multiOsContextCapable)
: gpuBaseAddress(baseAddress),
size(sizeIn),
cpuPtr(cpuPtrIn),
gpuAddress(gpuAddress),
memoryPool(pool),
allocationType(allocationType),
multiOsContextCapable(multiOsContextCapable) {}
GraphicsAllocation::GraphicsAllocation(void *cpuPtrIn, size_t sizeIn, osHandle sharedHandleIn, bool multiOsContextCapable)
GraphicsAllocation::GraphicsAllocation(AllocationType allocationType, void *cpuPtrIn, size_t sizeIn, osHandle sharedHandleIn,
MemoryPool::Type pool, bool multiOsContextCapable)
: size(sizeIn),
cpuPtr(cpuPtrIn),
gpuAddress(castToUint64(cpuPtrIn)),
sharedHandle(sharedHandleIn),
memoryPool(pool),
allocationType(allocationType),
multiOsContextCapable(multiOsContextCapable) {}
GraphicsAllocation::~GraphicsAllocation() = default;