Programs scope pointers should point to objects in constant AS or for OpenCL 2.0 in global AS.
Details
Details
Diff Detail
Diff Detail
Event Timeline
Comment Actions
I am not sure about the restriction that program scope pointer must point to global or constant addr space. Can you provide reference to the OpenCL 2.0 spec?
https://www.khronos.org/registry/cl/specs/opencl-2.0-openclc.pdf
On page 36 there are examples for program-scope pointers:
int *foo; // OK. foo is allocated in global address space.
// pointer to foo in generic address space
int * global ptr; // OK.
It seems at least program-scope pointers pointing to generic addr space is also allowed.
Check alignment of comments.