[SOLVED] Can I properly enable OpenCL on Windows 11 and Intel Iris Xe graphics in Darktable 4.0?

I got the same issue on older gpu

[opencl_init] opencl related configuration options:
[opencl_init] opencl: ON

[dt_opencl_device_init]
DEVICE: 0: 'Intel(R) HD Graphics 520’
CANONICAL NAME: intelrhdgraphics520
PLATFORM NAME & VENDOR: Intel(R) OpenCL HD Graphics, Intel(R) Corporation
DRIVER VERSION: 30.0.101.1994
DEVICE VERSION: OpenCL 3.0 NEO
DEVICE_TYPE: GPU
…
*** marked as disabled ***
[opencl_init] no suitable devices found.
[opencl_init] FINALLY: opencl is NOT AVAILABLE on this system.
[opencl_init] initial status of opencl enabled flag is OFF.

If you can point me to the correct config option in darktablerc to override the blacklisting, that will be great. In the meantime, I plan to recompile darktable on my PC by modifying that blacklist header file to remove the blacklisting on Windows.

EDIT: The config option seems to be opencl_disable_drivers_blacklist=TRUE. But that still did nothing… hmmm…

There are good reasons for blacklisting. You can try the device conf key setting described in the link too but NEO ist just outdated.

You really should look for recent drivers, Intel definetly has docs…

I think you have outdated information. I think NEO is simply the code name for this driver but these are the latest drivers.

I have Intel UHD graphics (IceLake) on Linux. The device version is listed as OpenCL 3.0 NEO but OpenCL is available. I have the latest Intel drivers.

I think I got it to work! It looks like there is a bug in the code which makes it not fully respect the opencl_disable_drivers_blacklist=TRUE config parameter. And also I had to delete already registered configurations for my devices from the darktablerc file under the names cldevice_v4_intelririsrxegraphics etc. Then, re-run the darktable-cltest.exe two times for it to compile the kernel modules for my GPU. And now OpenCL works :slight_smile:

More detailed solution:

How to fix the issue with OpenCL not working on Windows with an Intel integrated graphics:
(As of Darktable version 4.0)

  • Go to C:\Users<Username>\AppData\Local\darktable
  • Open the darktablerc file. Search for already configured CL devices: these will have config keys starting with cldevice_
  • Delete all the lines starting with cldevice_ to essentially delete already configured devices for OpenCL.
  • Check if there is a already a line starting with opencl_disable_drivers_blacklist=. If so, add TRUE at the end or else, add a new line with opencl_disable_drivers_blacklist=TRUE
  • Go to the Darktable bin folder where you will find darktable_cltest.exe. At the moment, due to a bug, you will have to run the following command twice to properly setup your integrated GPU to use OpenCL: darktable-cltest.exe -d opencl (if they incorporate my bug fix, then you only need to run this command once)
    • You probably don’t have to run darktable-cltest.exe but perhaps just open darktable and it may also setup OpenCL devices
8 Likes

Yes, on Linux this driver is not blacklisted. On Windows it is still left blacklisted since 2019. I really don’t think it needs to be… Had to override it. Anyway got it to work now. But there is definitely a bug in their code and I will send a bug fix to make this flag work correctly the first time.

1 Like

bravo, it works also for my older card.

Note that @wpferguson has been making weekly windows builds of master. It seems not enough windows users have been using them, as bugs are being found post release. Darktable does not have enough windows testers. If you want a better release version, start testing the master builds when we get close to release.

4 Likes

I have commented your pr https://github.com/darktable-org/darktable/pull/12155

explaining why i think it’s not correct.

1 Like

In my case, I just had to delete the two lines in darktablerc file
cldevice_v4_intelrhdgraphics520=0 250 0 16 16 128 0 1 0.000000 cldevice_v4_intelrhdgraphics520_id0=400
then using darktable_cltest.exe, two new lines were written on that file
cldevice_v4_intelrhdgraphics520=0 250 0 16 16 128 0 0 0.118311 cldevice_v4_intelrhdgraphics520_building=-cl-fast-relaxed-math
any way thanks a lot for your quick answers

Just wondering - Is darktable’s availability on Windows an official aim of the project, or just because someone is available to port it (for whatever effort that requires)? I realize at some level obviously “someone’s availability” is a requirement for everything. I’m just curious if a Windows binary is a core goal or an added bonus. A minor point that triggered my question is the occasional assumption in the docs that it’s running on Linux. That may just be a by-product of DT’s roots.

Thanks.

The code is there on the repo and instructions are provided to compile it for WIn, MacOS and flavours of Linux…I think the focus on the code as it is developed is a working Linux version and then people assist with porting it to WIndows and Mac… and subsequently troubleshooting specific OS issues…

1 Like

@priort is correct, the code is there in the repo and changes to increase stability on any platform are generally accepted. Windows is a goal as long as someone is there to contribute to it. Most of the developers use Linux and so it runs best there.

The project is definely short on Windows developers and testers; you can see this as now that 4.0 is released, there are some (IMO) easy to spot bugs being reporter that only affect windows.

@wpferguson makes a weekly windows build I wish more people would use, then we would have less bugs at release time. But its only as good as people make it.

Before 4’s GA release I was using the weekly builds regularly. I’ve not updated since but will. My biggest problem right now is that I’m just not shooting much, hence little editing. I guess my workflow hasn’t hit too many of the bugs so far.

Thanks Thanks Thanks.

Hi all,

I’m testing the latest Windows development build by @wpferguson and I noticed that this issue is still present for Intel Iris Xe graphic.

I can workaround the issue by following the extract instruction below, however, what is required to include the official fix in the final release?

Okay I read further and found that the issue can simply be work around by changing a single setting from 1 to 0

From here: darktable 4.6 user manual - memory & performance tuning

h. disable device
0 = enable device; 1 = disable device
If darktable detects a malfunctioning device it will automatically mark it as such by setting this parameter to 1. If you have a device that reports a lot of errors you can manually disable it by setting this field to 1.

However, the question remains that why is the Windows NEO driver is still blacklisted despite there has been a bug fix that should have fixed the original issue.

What test on Windows can be done to prove that the blacklist can be removed?

1 Like

Start an Issue in GitHub for Feature Request to remove the Neo as blacklisted for windows. Provide screenshots or some info that shows it working on your system with current drivers. Test using multiple heavy openCL modules (D&S). Without an issue and test data, it will remain blacklisted. I run windows, buy i don’t have an Intel, so i cant test it.

Absolutely! I think it would be far worse to remove it from blacklist and get lost of user complaints about dt crashing or doing other bad things than “just set one 1 to 0”. The mentioned “bug fix” was a fix but not the reason for blacklisting.

Another option would be: you could start a windows user survey about “How does NEO work?”