1. Computers
  2. Display Drivers
  3. Graphics Cards
  4. Memory
  5. Motherboards
  6. Processors
  7. Software
  8. Storage
  9. Operating Systems


Facebook RSS Twitter Twitter Google Plus


Phoronix Test Suite

OpenBenchmarking.org

How To Begin Using OpenCL With Radeon Gallium3D

AMD

Published on 17 March 2012 02:56 PM EDT
Written by Michael Larabel in AMD
2 Comments

Earlier this month I wrote about how you can sort of begin using OpenCL acceleration out of the Radeon Gallium3D driver, but in the short time since, the code has continued to advance and now here's a guide for trying out this GPGPU computing technology on the open-source Radeon Linux driver.

Tom Stellard, the AMD employee that's been working on LLVM and OpenCL support within their open-source driver stack for the past several months, has finally blogged about the OpenCL progress: Testing clover with r600g.

Stellard's Radeon OpenCL work builds upon the Clover Gallium3D state tracker that's now a few years old, the GSoC work done last summer, the Nouveau OpenCL EVoC work (as shown in that article, OpenCL is now working for open-source NVIDIA), and this work continues to rely upon LLVM/Clang. Another developer, Ádám Rák, also recently wrote an R600 Gallium3D compute implementation.

This Radeon OpenCL support (for now at least) is being limited to Evergreen (Radeon HD 5000 series) and Northern Islands (Radeon HD 6000 series, but the HD 6900 Cayman GPUs aren't yet supported) and various out-of-tree bits.

On the DRM side, the Linux 3.1 kernel or newer will have you suited. For the Mesa/Gallium3D side, you currently need to use clover-r600-master from Tom Stellard's personal Mesa Git repository.

Additionally, the OpenCL 1.1 headers must be installed, the latest development LLVM/Clang snapshot needs to be used (from SVN/Git) and some patches applied there, and you also need to be using Tom's Git repository of libclc.

When all of the above factors are met, there should be basic OpenCL support in place for the HD 5000/6000 (non-Cayman) graphics processors. It will be interesting to check out to see how the OpenCL compute performance is on the open-source stack relative to AMD's Catalyst proprietary driver and its OpenCL implementation. As well, it will be interesting to see how the OpenCL support compares to that of Nouveau Gallium3D compute.

The next challenge will be to finally mainline all of this OpenCL work. Ideally we could see this happen for Mesa 8.1. This would be ideal to see since besides Mesa developers still being years behind with catching up to the latest OpenGL specifications, they're also years behind in the OpenCL support.

Aside from Mesa/Gallium3D itself, there will then need to be the release of LLVM/Clang 3.1 (likely to come in H2'2012) and a unified libclc. Hopefully all of this work will finally come together by year's end or ideally by the time of Ubuntu 12.10 / Fedora 17 (otherwise Ubuntu 13.04 / Fedora 18) so that Linux users can finally benefit from "out of the box" open-source OpenCL support. At that point, the OpenCL 1.0 specification will be four years old (it was ratified in December of 2008).

About The Author
Michael Larabel is the principal author of Phoronix.com and founded the web-site in 2004 with a focus on enriching the Linux hardware experience and being the largest web-site devoted to Linux hardware reviews, particularly for products relevant to Linux gamers and enthusiasts but also commonly reviewing servers/workstations and embedded Linux devices. Michael has written more than 10,000 articles covering the state of Linux hardware support, Linux performance, graphics hardware drivers, and other topics. Michael is also the lead developer of the Phoronix Test Suite, Phoromatic, and OpenBenchmarking.org automated testing software. He can be followed via and or contacted via .
Latest Linux Hardware Reviews
  1. Intel Xeon E5-1680 v3 & E5-2687W v3 Compared To The Core i7 5960X On Linux
  2. Intel 120GB 530 Series SSD Linux Performance
  3. Btrfs/EXT4/XFS/F2FS RAID 0/1/5/6/10 Linux Benchmarks On Four SSDs
  4. AMD's Windows Catalyst Driver Remains Largely Faster Than Linux Drivers
Latest Linux Articles
  1. NVIDIA vs. Nouveau Drivers With Linux 3.18 + Mesa 10.4-devel
  2. Is The Open-Source NVIDIA Driver Fast Enough For Steam On Linux Gaming?
  3. Linux 3.18 File-System Performance Minimally Changed But Possible Regressions
  4. AMD Radeon Gallium3D Is Catching Up & Sometimes Beating Catalyst On Linux
Latest Linux News
  1. Linux 3.18-rc6 Released, A Worrisome Regression Remains
  2. HandBrake 0.10 Brings H.265 & VP8 Encoders
  3. Gngr: A New Web Browser Focused On Privacy
  4. Linux 3.18 Kernel: Not Much Change With Intel Haswell Performance
  5. More File-System Tests Of The Linux 3.18 Kernel
  6. Using NVIDIA's NVENC On Linux With FFmpeg
  7. There's Talk Again About An "Open To The Core" Ubuntu Laptop
  8. PowerVR SGX Driver Code Gets Leaked
  9. V2 Of KDBUS Published For Linux Kernel Review
  10. VirtualBox 4.3.20 Arrives, Still No Sign Of VirtualBox 4.4
Latest Forum Discussions
  1. PulseAudio 6.0 Is Coming & Other Linux Audio Plans For The Future
  2. Debian Developer Resigns From The Systemd Maintainership Team
  3. Roadmap to Catalyst 14.10 ?
  4. Updated and Optimized Ubuntu Free Graphics Drivers
  5. Cant get working Kaveri APU - A10-7850k
  6. Script for Fan Speed Control
  7. Debian Init System Coupling Vote Results
  8. The Slides Announcing The New "AMDGPU" Kernel Driver