Cannot use opencl on Cape Verde: [opencl_init] could not create command queue for device 0: -6
After discontinuing fglrx I was left without fast darktable for more than half a year on my 7770 Cape Verde...
The last attempt to make it working was the closest: I could install opencl blob and it is visible with clinfo but is still inoperable.
I've opened a bug @ gentoo bugzilla https://bugs.gentoo.org/show_bug.cgi?id=627998
but the maintainers asked me for more info I can not provide.
I do realize that most probably it's not darktable issue at all (other apps seem not to work either) but I ask somebody who can help to participate in the discussion over there to triangle the problem and possibly find a solution.
#1 Updated by Ulrich Pegelow 9 months ago
From darktable-cltest's output:
[opencl_init] could not create command queue for device 0: -6
Error code -6 relates to CL_OUT_OF_HOST_MEMORY. And that's what the docs tell us about this error during command queue creation:
CL_OUT_OF_HOST_MEMORY if there is a failure to allocate resources required by the OpenCL implementation on the host.
I guess it's a driver bug.
#3 Updated by Josep V. Moragues 9 months ago
I get the same error with my Radeon R7 250 (GCN 1.0) on a clean install of Ubuntu GNOME 16.04.3, and the newest AMDGPU-PRO driver (17.30)
./darktable-cltest [opencl_init] opencl related configuration options: [opencl_init] [opencl_init] opencl: 1 [opencl_init] opencl_library: '' [opencl_init] opencl_memory_requirement: 512 [opencl_init] opencl_memory_headroom: 100 [opencl_init] opencl_device_priority: '*/!0,*/*/*' [opencl_init] opencl_mandatory_timeout: 200 [opencl_init] opencl_size_roundup: 16 [opencl_init] opencl_async_pixelpipe: 0 [opencl_init] opencl_synch_cache: 0 [opencl_init] opencl_number_event_handles: 25 [opencl_init] opencl_micro_nap: 1000 [opencl_init] opencl_use_pinned_memory: 0 [opencl_init] opencl_use_cpu_devices: 0 [opencl_init] opencl_avoid_atomics: 0 [opencl_init] [opencl_init] found opencl runtime library 'libOpenCL' [opencl_init] opencl library 'libOpenCL' found on your system and loaded [opencl_init] found 1 platform [opencl_init] found 1 device [opencl_init] device 0 `Capeverde' supports image sizes of 16384 x 16384 [opencl_init] device 0 `Capeverde' allows GPU memory allocations of up to 332MB [opencl_init] device 0: Capeverde GLOBAL_MEM_SIZE: 518MB MAX_WORK_GROUP_SIZE: 256 MAX_WORK_ITEM_DIMENSIONS: 3 MAX_WORK_ITEM_SIZES: [ 256 256 256 ] DRIVER_VERSION: 2442.7 DEVICE_VERSION: OpenCL 1.2 AMD-APP (2442.7) [opencl_init] could not create command queue for device 0: -6 [opencl_init] FINALLY: opencl is NOT AVAILABLE on this system. [opencl_init] initial status of opencl enabled flag is OFF.
Darktable's OpenCL works fine with this card on Ubuntu GNOME 14.04 with the discontinued fglrx driver.
#6 Updated by Fernando Iguacel 8 months ago
Just tried the solution on https://github.com/fireice-uk/xmr-stak-amd/issues/69
and darktable-cltest just worked
#7 Updated by Nick Kachulin 8 months ago
- File 20170923_0024.jpg added
I can confirm that darktable-cltest reports okay.
However, darktable produces artifacts on the screen when working with such setup. When I tried to export something it stucks the kernel. Lovering percentage from 100 to 80 did the trick but with artifacts, too.
One step further but not there yet...
UPD: Actually only GPU_FORCE_64BIT_PTR=1 is enough but it produces artifacts.
UPD1: Tried other program -- artifacts are produced, too. So it's still an opencl issue.