darktable and OpenCL on Mac Retina running bare metal Linux

Finishing up the carbon copy clone now. May try the live boot first, see what it reveals. Thanks

No love for openCL with a Manjaro install. Installed a bunch of opencl drivers (the kitchen sink approach) got past the usual "can’ find libopencl stuff in the terminal window, and got to a segfault where dt won’t open at all. Will try another distro, or try again using the MacOS version of dt to see what happens.

So no luck on Mint either. Installed the latest dt version on macOS, openCl not enabled. Funny that opneCL is enabled in Photoshop. Oh well, might be time for a new laptop once I have someplace I can travel to!

The clinfo cli tool helped me a lot, at least as a quick check on whether the openCL is active. It’s a lot easier than debugging darktable.

So is this something to run on LInux or MacOS? Thanks

No luck with installing the intel-opencl driver package, although running dartable -d opencl got past the “no opencl lib warning” before closing with a segfault. Wonder if an appimage would solve this problem?

Unlikely, as it’d probably rely on the system’s openCL drivers.

Looks like the solution is a new laptop sometime down the road.

I think I can help :wink:
I use darktable on Manjaro as well. darktable 3.2.1 failed to start with a segfault due to the newest version of the package intel-graphics-compiler (1.0.4427). Downgrading the package to version 1.0.4361 solved the issue for me (as it is described here: SegFault with OpenCL Intel NEO driver installed · Issue #6003 · darktable-org/darktable · GitHub).

1 Like

Thanks, I’ll check it out.

Well, that got me past the segfault, but still no openCL working. Thanks for the help.

It might be a stupid bunch of questions, but… (consider it a little checklist):
Did you install all necessary drivers for OpenCL?
Did you perform a darktable-cltest in the commandline? What does it say?
Did you check the settings for OpenCL in the settings menu?

No question is stupid, but my answers often are.

I never know if I have installed all the drivers, as I don’t really know what is needed.
I threw the kitchen sink at this, and don’t know what I might need to further install.
Here’s the output of the darktable cl test:

darktable -d opencl

0.093223 [opencl_init] opencl related configuration options:
0.093284 [opencl_init]
0.093292 [opencl_init] opencl: 1
0.093298 [opencl_init] opencl_scheduling_profile: ‘default’
0.093304 [opencl_init] opencl_library: ‘’
0.093311 [opencl_init] opencl_memory_requirement: 768
0.093317 [opencl_init] opencl_memory_headroom: 400
0.093323 [opencl_init] opencl_device_priority: ‘/!0,///!0,*’
0.093347 [opencl_init] opencl_mandatory_timeout: 200
0.093354 [opencl_init] opencl_size_roundup: 16
0.093360 [opencl_init] opencl_async_pixelpipe: 0
0.093366 [opencl_init] opencl_synch_cache: active module
0.093372 [opencl_init] opencl_number_event_handles: 25
0.093378 [opencl_init] opencl_micro_nap: 1000
0.093384 [opencl_init] opencl_use_pinned_memory: 0
0.093392 [opencl_init] opencl_use_cpu_devices: 0
0.093398 [opencl_init] opencl_avoid_atomics: 0
0.093403 [opencl_init]
0.093657 [opencl_init] found opencl runtime library ‘libOpenCL’
0.093703 [opencl_init] opencl library ‘libOpenCL’ found on your system and loaded
0.197276 [opencl_init] found 1 platform
0.197345 [opencl_init] could not get device id size: -1
0.197355 [opencl_init] found 0 device
0.197361 [opencl_init] FINALLY: opencl is NOT AVAILABLE on this system.
0.197367 [opencl_init] initial status of opencl enabled flag is OFF.

In the GUI, OpenCl is not activated (not available)

These are all tests on a Parallels Mac host, using a Manjaro Linux Gnome client.
I get the same results on a VMware Host or a Vbox host.

Running darktable on the Mac Catalina OS OpenCl is active. I have not done any testing of this version 3.2.1 on the Mac yet. Previously on darktable 3.0.1, I had so many crashes that I got more done using the Vbox install without OpenCl.

I’ll probably do some more testing on the MacOS native install and see if anything has improved. It’s one of life’s little mysteries !

Okay, I think we found the root of your problem. You are trying to use your iGPU in a virtual machine, afaik that won’t work hence OpenCL is deactivated.

Thanks- I guess we can put that to bed! I’ll do a bit of testing on the MacOS install and see if the OpenCL crashes on the new version 3.2.1 have gone away. The laptop is what I use when traveling, and there isn’t any of that happening these days.

As an aside, I started looking at Linux notebooks, and they are very expensive here in the US. Time to start saving up me thinks.

Thanks again for your time and help.

You can get almost any decent notebook with Windows and convert it to Linux, easily. I run Fedora 32 on an HP Probook 450 G3 (several years old, now) that I bought new for less than $1000.

I think next time around for a laptop I may try that route. I try tp keep up with the Reddit Linux hardware thread, but the hardware changes so rapidly it’s hard to know what will fully work and what won’t. In the meantime, the Macbook Pro I bought last year used is really solid except for the openCL issue, which doesn’t affect me much. Running the VM on it has been pretty good except for the recent MacOS update that broke Vbox. Hopefully it will be fixed in October.

I have used DT on MacBook pros with Iris graphics and on Linux laptops with mobile Nvidia.
On MBPs with MacOS openCL works but the performance gain is marginal. With mobile Nvidia it’s like night and day, worth the extra cost.

FWIW on desktop, I used AMD bus powered cards (rx560) with the open-source rocm driver for a few of years but had lots of small issues and AMD was very slow to fix anything and they wouldn’t support popular distributions (just them and Ubuntu LTS). Eventually I gave up on supporting AMD and changed to Nvidia 1650, also bus powered (it’s a silent workstation with no fans and a small power supply) and it was night and day, I measured double the performance vs rx560. And all the small issues were gone. Nvidia open source policy and attitude stinks but at least the proprietary SW works really well, all distros support it and the hardware is superb.

Is the mobile Nvidia card a replacement for the onboard Intel Iris card? I could’nt find much info on the web, other than some chatter about power issues. I haven’t tested the new version 3.0.1 on the MacOs yet to see if the stability issues have been solved. I did notice that the performance without OpenCL on the Linux Vbox system was not much different without OpenCL.

I’ve been running my desktop which is an HPEnvy from Costco for 6 months now with it’s Radeon RX550 card with no problems. It took a bit of searching to get the right drivers in, and these instructions worked for me:
https://haefelfinger.ch/posts/2019/2019-01-02-Darktable-Radeon-OpenCL/

Thanks for your info.

Nvidia mobile is discrete graphics but I don’t think it’s a card that you can add ir upgrade

In the Mac I have been using DT 3.2, the latest. I’ve done some casual editing so far and had no issues. It’s a vast improvement compared to 3.0