Arm Community
Site
Search
User
Site
Search
User
Groups
Education Hub
Open Source Software and Platforms
Research Collaboration and Enablement
Forums
AI and ML forum
Architectures and Processors forum
Arm Development Platforms forum
Arm Development Studio forum
Arm Virtual Hardware forum
Automotive forum
Compilers and Libraries forum
Graphics, Gaming, and VR forum
High Performance Computing (HPC) forum
Infrastructure Solutions forum
Internet of Things (IoT) forum
Keil forum
Morello forum
Operating Systems forum
SoC Design and Simulation forum
SystemReady Forum
Blogs
AI and ML blog
Announcements
Architectures and Processors blog
Automotive blog
Graphics, Gaming, and VR blog
High Performance Computing (HPC) blog
Infrastructure Solutions blog
Internet of Things (IoT) blog
Operating Systems blog
SoC Design and Simulation blog
Tools, Software and IDEs blog
Support
Arm Support Services
Documentation
Downloads
Training
Arm Approved program
Arm Design Reviews
Community Help
More
Cancel
Support forums
Arm Development Platforms forum
clImportMemoryARM return CL_OUT_OF_HOST_MEMORY
Jump...
Cancel
State
Accepted Answer
Locked
Locked
Replies
1 reply
Subscribers
21 subscribers
Views
5735 views
Users
0 members are here
Options
Share
More actions
Cancel
Related
How was your experience today?
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion
clImportMemoryARM return CL_OUT_OF_HOST_MEMORY
qdev
over 3 years ago
The code is like this:
cl_mem buffer = clImportMemoryARM(context,
CL_MEM_READ_WRITE,
NULL,
ptr,
size,
&err);
if ptr is a newly malloc buffer pointer, like
char* ptr = (char*)malloc(size);
it works fine.
However, when passing into a third party library pointer (accessible from CPU), let's call it coolPtr, it will return error code -6, which is CL_OUT_OF_HOST_MEMORY
cl_mem buffer = clImportMemoryARM(context,
CL_MEM_READ_WRITE,
NULL,
coolPtr,
size,
&err);
I can do other operations with coolPtr successfully, like I can
memcpy(dstPtr, coolPtr, size);
Then why does the clImportMemoryARM fail for coolPtr? Thanks!
Top replies
Zhifei Yang
over 3 years ago
+1
verified
It may depend on the clImportMemoryARM() implementation about the memory attribute check. Possibly, the third-party library pointer has different memory attributes (read/write/execute/shareability...