Cannot activate OpenCL on Windows 10

About a year ago I found that darktable would no longer activate OpenCL. I had figured that this was due to an AMD GPU driver update. I’ve spent the last few days trying to get to the bottom of this with no luck, and have gone through the manual as well as the related PIXLS topics, so I’m hoping someone could provide some insight.

The system is an HP All-in-One with AMD A8-7410 APU with AMD Radeon R5 integrated graphics with 8GB of installed RAM. I verified that the GPU has OpenCL 2.0 and that all of the drivers are up to date. While this system is modest, it does do its job but I would like to get some more performance out of it if possible.

When opening preferences, the options to activate OpenCL support and for OpenCL scheduling profile are greyed out.

My OpenCL settings in dartablerc are as follows:

opencl=true
opencl_async_pixelpipe=false
opencl_avoid_atomics=false
opencl_device_priority=/!0,///!0,*
opencl_disable_drivers_blacklist=true
opencl_library=
opencl_mandatory_timeout=200
opencl_memory_headroom=400
opencl_memory_requirement=768
opencl_micro_nap=1000
opencl_number_event_handles=25
opencl_scheduling_profile=default
opencl_size_roundup=16
opencl_synch_cache=active module
opencl_use_cpu_devices=false
opencl_use_pinned_memory=false

And I received these results from darktable-cltest:

0.287098 [opencl_init] opencl related configuration options:
0.307598 [opencl_init]
0.311045 [opencl_init] opencl: 1
0.318421 [opencl_init] opencl_scheduling_profile: ‘default’
0.330967 [opencl_init] opencl_library: ‘’
0.342469 [opencl_init] opencl_memory_requirement: 768
0.355059 [opencl_init] opencl_memory_headroom: 400
0.365387 [opencl_init] opencl_device_priority: ‘/!0,///!0,*’
0.377052 [opencl_init] opencl_mandatory_timeout: 200
0.388949 [opencl_init] opencl_size_roundup: 16
0.396828 [opencl_init] opencl_async_pixelpipe: 0
0.403341 [opencl_init] opencl_synch_cache: active module
0.409827 [opencl_init] opencl_number_event_handles: 25
0.415708 [opencl_init] opencl_micro_nap: 1000
0.421182 [opencl_init] opencl_use_pinned_memory: 0
0.427486 [opencl_init] opencl_use_cpu_devices: 0
0.431942 [opencl_init] opencl_avoid_atomics: 0
0.436758 [opencl_init]
0.445049 [opencl_init] found opencl runtime library ‘OpenCL.dll’
0.451694 [opencl_init] opencl library ‘OpenCL.dll’ found on your system and loaded
0.861869 [opencl_init] found 1 platform
0.874442 [opencl_init] found 1 device
0.879924 [opencl_init] device 0 Mullins' supports image sizes of 16384 x 16384 0.905973 [opencl_init] device 0 Mullins’ allows GPU memory allocations of up to 2093MB
[opencl_init] device 0: Mullins
CANONICAL_NAME: mullins
GLOBAL_MEM_SIZE: 3487MB
MAX_WORK_GROUP_SIZE: 256
MAX_WORK_ITEM_DIMENSIONS: 3
MAX_WORK_ITEM_SIZES: [ 1024 1024 1024 ]
DRIVER_VERSION: 3240.6
DEVICE_VERSION: OpenCL 2.0 AMD-APP (3240.6)
1.787956 [opencl_init] could not create command queue for device 0: -6
1.794029 [opencl_init] no suitable devices found.
1.799066 [opencl_init] FINALLY: opencl is NOT AVAILABLE on this system.
1.807767 [opencl_init] initial status of opencl enabled flag is OFF.

So I’m really in a quandry because I don’t know what caused OpenCL to stop functioning in darktable or what I can do about it. Thanks in advance for your help!

I’m not sure what the problem is, but the error code -6 means " CL_​OUT_​OF_​HOST_​MEMORY if there is a failure to allocate resources required by the OpenCL implementation on the host."

1 Like

Check DT host memory in preferences. Set it to 0 (0= no limit) so DT can use all of the 8Gb of memory you have.

1 Like

Thanks, I just tried that and nothing changed. The cltest still returns an error code -6.

Can you confirm that your drive supports opencl image?

@paperdigits, could you tell me how I would do that, or point me to a link? Thanks!

I’m not sure what else to try. Make sure you have the latest drivers from the amd website

1 Like

Looks like this is your own post, butnutd be nice to know the answers to what is asked there: Re: OpenCL disabled on AMD Radeon R5 - AMD Community

1 Like

I also had to uninstall OpenCL compatibility pack from windows apps. It was giving me problems with the Nvidia card. I doubt that your issue, but at least it is something else to try.

1 Like

Lol… it is a small world. I had just sent them a response. I verified through GPU-Z that OpenCL is available for this GPU and that it runs version 2.0, which is compatible with my software. I also went in an updated all of my drivers and am now running Radeon Software Version 21.5.2 , but that didn’t make any difference.

However, one of the responses had a screen shot of the Windows display settings that had an option to activate hardware accelerated GPU scheduling, which doesn’t appear on my system. So I have to wonder if that has something to do with the issue.

You can try here…

I have added two applications for my system in Windows…

image

1 Like

Thank you all for your advice. It seems that OpenCL is just not in the works for me. Somehow I will carry on… :wink: