8.3.2 Use CL_MEM_ALLOC_HOST_PTR
to avoid copying memory
The Mali™ GPU can access the memory buffers created by clCreateBuffer(CL_MEM_ALLOC_HOST_PTR). This is the preferred method to allocate buffers because data copies are not required.
This method of allocating buffers is shown in the following
Figure 8-1 Memory buffer created by clCreateBuffer(CL_MEM_ALLOC_HOST_PTR)
- You must make the initial memory allocation
through the OpenCL API.
Always use the latest pointer returned.
If a buffer is repeatedly mapped and unmapped, the address
the buffer maps into is not guaranteed to be the same.