Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Debugging seg-fault NVIDIA GPU #181

Open
ilaychen opened this issue Dec 15, 2019 · 2 comments
Open

Debugging seg-fault NVIDIA GPU #181

ilaychen opened this issue Dec 15, 2019 · 2 comments

Comments

@ilaychen
Copy link

Hi,
I'm trying to debug a segmentation fault in a kernel on NVIDIA GPU.
How can I get memory details when accessing specific variable inorder to know what is the reason for the segmentation fault.
Thanks!

@jrprice
Copy link
Owner

jrprice commented Jan 12, 2020

Apologies for the slow reply. Is the segmentation fault when using Oclgrind, or when running your OpenCL kernel on the GPU? It's not clear from your message. If there is an out-of-bounds memory access, Oclgrind should automatically print details about where it is coming from.

@Nabushika
Copy link

I got the same thing - you might want to check that the cl::Event is not null, can debug with gdb - if you're getting a null pointer access in libopencl.so then the problem is that the kernel execution isn't happening properly. In my case this was because there were (silently ignored) errors when setting the arguments for the kernel.
Hope this helps!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants