Choose BUFFER_HOST_MEMORY as type in 32 bit applications.

Change-Id: I33addbd37cb4b9192c2dfa88aeee6d6cbdafd714
This commit is contained in:
Mrozek, Michal
2018-12-07 16:12:07 +01:00
parent 481b83b436
commit c865dbbaa1
3 changed files with 37 additions and 9 deletions

View File

@@ -319,7 +319,9 @@ void Buffer::checkMemory(cl_mem_flags flags,
GraphicsAllocation::AllocationType Buffer::getGraphicsAllocationType(cl_mem_flags flags, bool sharedContext, bool renderCompressedBuffers) {
GraphicsAllocation::AllocationType type = GraphicsAllocation::AllocationType::BUFFER;
if (flags & CL_MEM_USE_HOST_PTR) {
if (is32bit) {
type = GraphicsAllocation::AllocationType::BUFFER_HOST_MEMORY;
} else if (flags & CL_MEM_USE_HOST_PTR) {
type = GraphicsAllocation::AllocationType::BUFFER_HOST_MEMORY;
} else if (renderCompressedBuffers) {
type = GraphicsAllocation::AllocationType::BUFFER_COMPRESSED;