- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
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
Link Copied
1 Reply
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Some questions:
- Which processor are you running on?
- Are you running a recent graphics driver? (You can compare your version with what is available at downloadcenter.intel.com.)
- Are you able to run SVM code, such as this sample? https://software.intel.com/en-us/articles/opencl-20-shared-virtual-memory-code-sample
The SVM sample uses a similar structure:
typedef struct _Element { global float* internal; //points to the "value" of another Element from the same array global float* external; //points to the entry in a separate array of floating-point values float value; } Element;
If you modify the sample to use your structure are you able to reproduce the behavior you're seeing?
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page