Hello, everyone!
I've some problem with Shared Virtual Memory and its buffers.
I've got structure like this:
typedef struct ListOfPtr ListOfPtr; struct ListOfPtr { cl_int some_value; ListOfPtr *first; ListOfPtr *last; ListOfPtr *next; ListOfPtr *prev; };
I declared a pointer of ListOfPtr type.
ListOfPtr *list = (ListOfPtr *)calloc(1, sizeof(ListOfPtr));
Then I get platform IDs, device IDs, creating a context and command queue...
Now I try to declare a pointer of SVM buffer:
ListOfPtr *list = (ListOfPtr *)clSVMAlloc(my_context, CL_MEM_READ_WRITE, sizeof(ListOfPtr) * 6, 0);
But something is going wromg and I've got error: Unable exception at 0x00000000 in MyCLProject.exe: 0xC0000005: Access Violation in the performance at 0x00000000.
Is there any solution of this problem?
P.S.: According to this my device has SVM support.
Thanks
Zone:
Thread Topic:
Question