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

Broken OpenGL/OpenCL interoperability support #778

Open
bobbyblues opened this issue Jun 15, 2016 · 4 comments
Open

Broken OpenGL/OpenCL interoperability support #778

bobbyblues opened this issue Jun 15, 2016 · 4 comments

Comments

@bobbyblues
Copy link

bobbyblues commented Jun 15, 2016

After a recent update, I cannot use OpenGL/OpenCL interoperability, though it had been working for about 2 years with no issue.

Note that OpenGL by itself still runs well on the Nvidia card, so does OpenCL, but as soon as I try to share data between the two, I get the following error message:

Xlib: extension "NV-GLX" missing on display ":0.0".

I'm not sure if a recent change in bumblebee is responsible for this, or if I need to reconfigure something. From what I get, the error is raised as soon as I use the "enqueueAcquireGLObjects" function from OpenCL.

I understand that the nvidia card actually runs on the display :8 by default, one workaround might be to tell OpenCL to run on this display as well, but I can't find how to do so.

@illuhad
Copy link

illuhad commented Oct 4, 2016

Any news on this? I have the same problem regarding OpenCL sharing, same error message. Sharing CUDA<->OpenGL works, so I assume my system configuration is correct. I use Arch Linux, with nvidia driver 370.28-1.

@s-ol
Copy link

s-ol commented Oct 29, 2018

Still experiencing the same issue, also on ArchLinux:

linux 4.18.14.arch1-1
nvidia 410.57-6
bumblebee 3.2.1-20
primus 20151110-7

@s-ol
Copy link

s-ol commented Oct 29, 2018

I can prevent my program from crashing by exporting DISPLAY=:8, but then I cannot see it's output.

This happens regardless of whether I set DISPLAY outside or inside primusrun:

env DISPLAY=:8 primusrun ...
primusrun env DISPLAY=:8 ...

@dcommander
Copy link

A customer reported a similar issue to me in the context of using a commercial OpenGL application with VirtualGL and TurboVNC. I was able to reproduce the issue with the OpenCL Marching Cubes Isosurfaces example from https://developer.nvidia.com/opencl. I don't know if you're experiencing exactly the same symptoms, but in our case, the crash occurs within the body of clEnqueueReleaseGLObjects() and is more specifically triggered by a call to glCreateSyncFromCLeventARB() followed by a call to glWaitSync() (the crash actually occurs within the body of glWaitSync(), which appears to be the point at which the nVidia proprietary driver stack is trying to use the non-existent NV-GLX extension.) NV-GLX is proprietary and undocumented, so there is no way to emulate it using an interposer such as VirtualGL or an X proxy such as TurboVNC. I am attempting to find someone at nVidia who can shed light on exactly what their OpenCL/OpenGL interop functions are doing and how I might be able to redirect the NV-GLX requests to the GPU-attached display. Presumably, if I figure anything out there, Bumblebee could take advantage of it as well.

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

No branches or pull requests

5 participants