Darktable would not open up on Windows

FWIW, I’ve just set up a new Win 11 laptop, with windows all up to date.
I was kind of hoping I might run into this issue, however Darktable. 4.4.2 runs perfectly out of the box.
The laptop does have an AMD discrete GPU, so the OpenCL compatibilty stuff is probably not involved I suppose… (It’s not installed as far as I can tell).

My 2 cents:

I had this problem after trying some AI software that installed the OpenCL layer from Microsoft on my AMD system. The magick error was thrown while building the cached kernels in the “C:\Users\kongstew\AppData\Local\Microsoft\Windows\INetCache\darktable\cached_v1_kernels_for_OpenCLOn12AMDRadeonRX6600M_110” (2nd device) directory. Shaders (correct me if this is the wrong term) for the AMDAcceleratedParallelProcessinggfx1032 (1st device) were created correctly. So the error seems to be caused by something in this OpenCLOn12 (GitHub - microsoft/OpenCLOn12: The OpenCL-on-D3D12 mapping layer) mapping layer. Similiar errors were thrown in the AI program when trying to use StableDiffusion.

After deinstalling the OpenCL mapping layer I only had 1 dt_opencl_device and darktable started as expected.

Just speculating: These kind of errors I’ve seen in the '90s when I dabbled in C and C++ and mostly they were caused by type casting gone wrong or something like that. I would think that somewhere a library is used/linked that is not as typesafe as we expect in 2023,

1 Like

Thanks all for the input and the willingness to solve this.

First off, I am unable to untick OpenCL support from Settings, it is greyed out, any idea how to get around this?

Secondly, to answer the diagnostics questions:

  1. Do you know what graphics card your {C has?
  • Intel HD Graphics 620
  1. Do you know the drivers? Can you go to the vendor website and update the drivers?
  • Driver for graphics card is version 27.20.100.8854, driver date 14/10/2020. This does sound old, but Windows tells me it is up to date.
  1. Do you have an antivirus running? Any alerts from it? Can you disable for a few minutes to test that’s not causing the issue?
  • No alerts. I also disabled the antivirus and the issue persists.

Can I provide any further details?

Go to this link and try this. It is almost the final version we will release in two weeks.

Second, go to Intel website and download the drivers from them for the GPU.

Installing the latest version of darktable did not fix the issue.
Having some trouble with updating the drivers, I am told my PC does not meet the minimum requirements for the latest driver from Intel. I will attempt to use SupportAssist to see what drivers they recommend.

Using the new version, if you disable opencl, in preference, do you still have an issue?

What’s the output of darktable-cltest with the new version?

Should I disable opencl by unticking all of the drivers?

The outputs of the cltest:

Yes try that. I’m not optimistic it will help. darktable --disable-opencl should help, but it is not the ideal solution.

If there is no supported driver, opencl won’t work.

Yes - you should do this as this should avoid starting OpenCL. Unfortunately you seem to installed some bad driver and that can’t be checked by dt. If the ticked intel driver doesn’t work you should either find a more recent/bugfree version or un-install that driver completely.

Thanks for that. I just clicked on the darktable icon and received the dialog box ‘‘An unhandled exception occurred’’.
The backtrace written is as follows:
darktable_bt_OHHMG2.txt (11.8 KB)

I know the discussion has moved on a bit, but you can do this:

by setting up a desktop shortcut and adding the flags to the target box:
image
In this case I have a bunch of stuff going on, but could just put the --disable-opencl on instead of the -d perf and so on.

Unfortunately, when launched from the shortcut, no log seems to be generated.

Interesting… it worked for me. See my other recent post about export issues. I got that log via the shortcut method.

Weird. I mean it’s weird that it didn’t work for Juan and it didn’t work for me. I see no reason why the parsing of the command-line arguments should be different.

1 Like

Yes. Odd. The first time I tried it I remember it didn’t work. I think (IIRC) it was to do with the positioning if those " " things in the target box.

We tried quite a few versions, see github.

1 Like

Very helpful, thanks!