Radeon 680M and opencl?

I have an Ubuntu 24.04 Beelink minipc.

# lspci -nnk | grep -A3 "\[03..\]:" 
e5:00.0 VGA compatible controller [0300]: Advanced Micro Devices, Inc. [AMD/ATI] Rembrandt [Radeon 680M] [1002:1681] (rev 0a)
	Subsystem: Advanced Micro Devices, Inc. [AMD/ATI] Rembrandt [Radeon 680M] [1002:0124]
	Kernel driver in use: amdgpu
	Kernel modules: amdgpu

Is there a chance to use opencl with [AMD/ATI] Rembrandt [Radeon 680M]?

In theory Radeon 680M supports opencl, but maybe there is an too old kernel in Ubuntu 24.04.

uname -r
6.8.0-59-generic
cpu:                                                            
                       AMD Ryzen 7 7735HS with Radeon Graphics, 2128 MHz
						...
keyboard:
                       Logitech Unifying Receiver
  /dev/input/event1    AT Translated Set 2 keyboard
  /dev/input/event14   CHERRY KW 7100 MINI Keyboard
mouse:
                       Logitech Unifying Receiver
  /dev/input/mice      HP Wireless Mouse X200
monitor:
                       BenQ PD2706U
graphics card:
                       ATI VGA compatible controller
sound:
                       ATI Audio device
                       AMD Family 17h (Models 10h-1fh) HD Audio Controller
storage:
                       Micron/Crucial P2 NVMe PCIe SSD
network:
  wlp2s0               Intel Wi-Fi 6 AX200NGW
  enp1s0               Realtek RTL8125 2.5GbE Controller
network interface:
  wlp2s0               Ethernet network interface
  lo                   Loopback network interface
  enp1s0               Ethernet network interface
disk:
  /dev/nvme0n1         Micron/Crucial P2 NVMe PCIe SSD
partition:
  /dev/nvme0n1p1       Partition
	...
usb controller:
                       AMD USB Controller
						...
bios:
                       BIOS
bridge:
						...
hub:
                       Linux Foundation 3.0 root hub
						...
memory:
                       Main Memory
bluetooth:
                       Intel AX200 Bluetooth
unknown:
                       FPU
                       DMA controller
                       PIC
                       Keyboard controller
                       AMD VanGogh PSP/CCP
                       AMD IOMMU
                       AMD Raven/Raven2/Renoir Sensor Fusion Hub
                       AMD Raven/Raven2/FireFlight/Renoir Audio Processor
                       AMD FCH SMBus Controller
                       Logitech Unifying Receiver

So is there any (easy) way to use opencl with my system?

Is it an igpu? Most likely it won’t work or be beneficial. You first need to install rocm-opencl.

3 Likes

Yes, it is a very very small pc. It is a Beelink SER 6, not shown at https://www.bee-link.com/ anymore, but looks similar. The area is similar to a mobile phone.

I want to give it a try.

Rendering time for boat-test-image is about 6sec using the cpu only and DT 5.

How? Is there a repo for Ubuntu?

Found:

rocm-cmake/noble 6.0.0-1 all
  AMD ROCm CMake modules

rocm-device-libs-17/noble 6.0+git20231212.5a852ed-2 amd64
  AMD specific device-side language runtime libraries

rocm-smi/noble 5.7.0-1 amd64
  ROCm System Management Interface (ROCm SMI) command-line interface
opencl-1.2-html-doc/noble 1.0~svn33624-5 all
  OpenCL 1.2 documentation - html pages

opencl-1.2-man-doc/noble 1.0~svn33624-5 all
  OpenCL 1.2 documentation - man pages (experimental)

opencl-c-headers/noble 3.0~2023.12.14-1 all
  OpenCL (Open Computing Language) C header files

opencl-clhpp-headers/noble 3.0~2023.12.14-1ubuntu1 all
  C++ headers for OpenCL development

opencl-clhpp-headers-doc/noble 3.0~2023.12.14-1ubuntu1 all
  documentation for C++ OpenCL headers

opencl-headers/noble 3.0~2023.12.14-1 all
  OpenCL (Open Computing Language) header files

I’m familiar with beelink. I have one as my home self hosting server.

I don’t know ubuntu.

1 Like

Any hint how to install rocm-opencl?

The system doesn’t offer to install amd propritary drivers, none found.

The benchmarks seem to hint that it’s 'bout as powerful as my Iris Xe, which brings some boost in performance, depending on module

1 Like

Run darktable -d perf with and without opencl and export an image using the same xmp. That way you can test on your system.

1 Like

I really don’t know. Google search or search here. Or switch to fedora. :slight_smile:

1 Like

For tests I recommend the following:

Download:

With Ubuntu 24.04 I had some problems with the installation.

After installation run:

apt update
apt upgrade
apt install --fix-missing

At least this helped here.

Run in a shell after installation:

phoronix-test-suite benchmark system/darktable

Always select all tests.

I don’t remember the link for the upload, so maybe someone can explain how to find phoronix darktable-tests with specified components?

Interesting is always to compare, Sorry, I don’t know what Iris Xe** is and it only helps, if you know the image, which was rendered.

I am especially interested in the boat test-image.

If you have working opencli the phoronix darktable test will show the difference between cpu only and opencli-acceleration.

Sorry I can’t post a link, at the moment, i do fresh installs with some pcs.

You don’t need to benchmark darktable (which is what the pharonix test suite does, but it isn’t really useful here, as it usually the old pipeline), but rather just use darktable-cltest as that’ll give specific information about each module in the pipeline.

1 Like

This would be the next step, if opencl works. At the end I don’t care about the exact test-time. With an old pc with `a NVidia TU116 card, opencl accelates rendering about 30%. Such a comparison value I would like to see with this pc.

I wondered that the minipc has about the same benchmarks as a desktop pc. I am comparing AMD Ryzen 7 3700X vs. AMD Ryzen 7 7735HS

There is:
https://repo.radeon.com/amdgpu-install/latest/ubuntu/noble/

I need an experienced AMD ubuntu-user. Is it simple sudo dplg -i https://repo.radeon.com/amdgpu-install/latest/ubuntu/noble/amdgpu-install_6.4.60400-1_all.deb

$ darktable-cltest 
darktable 5.0.1
Copyright (C) 2012-2025 Johannes Hanika and other contributors.

Compile options:
  Bit depth              -> 64 bit
  Debug                  -> DISABLED
  SSE2 optimizations     -> ENABLED
  OpenMP                 -> ENABLED
  **OpenCL                 -> ENABLED**
  Lua                    -> ENABLED  - API version 9.4.0
  Colord                 -> ENABLED
  gPhoto2                -> ENABLED
  GMIC                   -> ENABLED  - Compressed LUTs are supported
  GraphicsMagick         -> ENABLED
  ImageMagick            -> DISABLED
  libavif                -> DISABLED
  libheif                -> ENABLED
  libjxl                 -> ENABLED
  LibRaw                 -> ENABLED  - Version 0.22.0-Devel202403
  OpenJPEG               -> ENABLED
  OpenEXR                -> ENABLED
  WebP                   -> ENABLED

See https://www.darktable.org/resources/ for detailed documentation.
See https://github.com/darktable-org/darktable/issues/new/choose to report bugs.

     0.4426 [dt_get_sysresource_level] switched to 1 as `default'
     0.4426   total mem:       11690MB
     0.4426   mipmap cache:    1461MB
     0.4426   available mem:   5845MB
     0.4426   singlebuff:      91MB
     0.4629 [opencl_init] opencl disabled via darktable preferences
     0.4631 [dt_dlopencl_init] could not find default opencl runtime library 'libOpenCL'
     0.4631 [dt_dlopencl_init] could not find default opencl runtime library 'libOpenCL.so'
     0.4632 [opencl_init] opencl library 'libOpenCL.so.1' found on your system and loaded, preference 'default path'
     0.4632 [opencl_init] 0 platforms detected, error: Unknown OpenCL error
     0.4632 [opencl_init] FINALLY: **opencl PREFERENCE=OFF is NOT AVAILABLE** and NOT ENABLED.

Here is a test with this minpc:

I am playing now with another minipc. I did the following:

dpkg -i amdgpu-install_6.4.60400-1_all.deb

amdgpu-install

amdgpu-setup --add-rocm

After reboot there is still no opencl seen.

Do I have to activate something?

whats the output of clinfo?

1 Like
$ clinfo
Number of platforms                               1
  Platform Name                                   AMD Accelerated Parallel Processing
  Platform Vendor                                 Advanced Micro Devices, Inc.
  Platform Version                                OpenCL 2.1 AMD-APP (3649.0)
  Platform Profile                                FULL_PROFILE
  Platform Extensions                             cl_khr_icd cl_amd_event_callback 
  Platform Extensions function suffix             AMD
  Platform Host timer resolution                  1ns

  Platform Name                                   AMD Accelerated Parallel Processing
Number of devices                                 0

NULL platform behavior
  clGetPlatformInfo(NULL, CL_PLATFORM_NAME, ...)  AMD Accelerated Parallel Processing
  clGetDeviceIDs(NULL, CL_DEVICE_TYPE_ALL, ...)   No devices found in platform [AMD Accelerated Parallel Processing?]
  clCreateContext(NULL, ...) [default]            No devices found in platform
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_DEFAULT)  No devices found in platform
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_CPU)  No devices found in platform
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_GPU)  No devices found in platform
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_ACCELERATOR)  No devices found in platform
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_CUSTOM)  No devices found in platform
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_ALL)  No devices found in platform

ICD loader properties
  ICD loader Name                                 OpenCL ICD Loaderns
  ICD loader Vendor                               OCL Icd free softwarens
  ICD loader Version                              2.3.2ns
  ICD loader Profile                              OpenCL 3.0ns
~# lshw -c video
  *-display                 
       Beschreibung: VGA compatible controller
       Produkt: Rembrandt [Radeon 680M]
       Hersteller: Advanced Micro Devices, Inc. [AMD/ATI]
       Physische ID: 0
       Bus-Informationen: pci@0000:e5:00.0
       Logischer Name: /dev/fb0
       Version: 0a
       Breite: 64 bits
       Takt: 33MHz
       Fähigkeiten: pm pciexpress msi msix vga_controller bus_master cap_list fb
       Konfiguration: depth=32 driver=amdgpu latency=0 mode=3840x2160 resolution=3840,2160 visual=truecolor xres=3840 yres=2160
       Ressourcen: iomemory:7f0-7ef iomemory:7f0-7ef irq:48 memory:7fe0000000-7fefffffff memory:7ff0000000-7ff01fffff ioport:e000(Größe=256) memory:dc400000-dc47ffff
# lspci -nnk | egrep -i --color 'vga|3d|2d' -A3 | grep 'in use'
	Kernel driver in use: amdgpu
# lspci -nnk | grep -i vga -A3 | grep 'Kernel modules':
	Kernel modules: amdgpu
~# hwinfo --gfxcard
17: PCI e500.0: 0300 VGA compatible controller (VGA)            
  [Created at pci.386]
  Unique ID: Jhgp.fvfrt1MfeU9
  Parent ID: JZZT.S7qSnXIRN5E
  SysFS ID: /devices/pci0000:00/0000:00:08.1/0000:e5:00.0
  SysFS BusID: 0000:e5:00.0
  Hardware Class: graphics card
  Model: "ATI VGA compatible controller"
  Vendor: pci 0x1002 "ATI Technologies Inc"
  Device: pci 0x1681 
  SubVendor: pci 0x1002 "ATI Technologies Inc"
  SubDevice: pci 0x0124 
  Revision: 0x0a
  Driver: "amdgpu"
  Driver Modules: "amdgpu"
  Memory Range: 0x7fe0000000-0x7fefffffff (ro,non-prefetchable)
  Memory Range: 0x7ff0000000-0x7ff01fffff (ro,non-prefetchable)
  I/O Ports: 0xe000-0xefff (rw)
  Memory Range: 0xdc400000-0xdc47ffff (rw,non-prefetchable)
  IRQ: 48 (no events)
  Module Alias: "pci:v00001002d00001681sv00001002sd00000124bc03sc00i00"
  Driver Info #0:
    Driver Status: amdgpu is active
    Driver Activation Cmd: "modprobe amdgpu"
  Config Status: cfg=new, avail=yes, need=no, active=unknown
  Attached to: #28 (PCI bridge)

Primary display adapter: #17

so clinfo tells you there are no opencl devices. And from Does latest ROCm 6.0 support Radeon 680M(gfx1035) ? · ROCm/ROCm · Discussion #2932 · GitHub it seems 680M is no longer supported even with the override.

Maybe try if rusticl works.

1 Like

Don’t know how to install it, but doese rusticl now support images? Read somewhere, it doesn’t.

https://www.reddit.com/r/ROCm/comments/1438p6t/how_to_install_rocm_opencl_on_ubuntu_2304_rx580/ gives some info.

Yes, it does.

1 Like

Can you say more about the state of the rusticl support in darktable?
I used it for some time in the past - maybe 1 year or so ago. It wasn’t really satisfying. It was significantly slower than rocm and I had often strange artefacts. Is it worth to give it a second try in the meantime? I’m at the moment still on Radeon RX 5700XT.

1 Like

It works fine. When mesa 25.1.1. comes to arch I could do some benchmarks again

2 Likes