Message boards : GPUs : Why Doesn't and When Will BOINC Support GPUs Via Open-Source OpenCL Drivers?
Message board moderation
Author | Message |
---|---|
Send message Joined: 8 Dec 13 Posts: 51 |
So, as I'm sure some people on this list know, AMD/ATi proprietary drivers are a nightmare on Linux (especially right now) and I had to give up trying to make them work after a recent Linux upgrade. It got me thinking, though, why doesn't BOINC recognize my OpenCL GPUs with the open-source drivers, which seem to be quite mature, now. I've looked into this twice before, but didn't pursue it because I was able to get proprietary drivers working. Now, I have to ask: does anyone know how to get BOINC to work this way? clinfo finds my GPUs just as it did two years ago and now the open-source drivers have even made it to OpenCL v1.2 compliance. BOINC actually does recognize OpenCL CPU resources (pocl). So, why not the other ones that clinfo finds? I know this doesn't mean the project I want to run will support such GPUs; I remember that. That's a separate issue. But, the first step is getting BOINC to support it, right? So, where are we now and what's between us and that goal? If you don't know, can you suggest who I might ask? |
Send message Joined: 20 Nov 12 Posts: 801 |
BOINC supports any OpenCL driver that works as an OpenCL ICD regardless of the driver's license. It's pretty hard to tell why it doesn't work for you as you didn't provide all that many details. Please see When requesting help on these forums thread. |
Send message Joined: 8 Dec 13 Posts: 51 |
Thanks Juha! I didn't provide details because I thought it was common experience in this community, but I'm glad to hear it is not! I hope that means someone can help me fix it. My mistake! I install all the OpenCL-related software I can find available in my distribution and when I switch to the open-source drivers--i.e. remove proprietary driver--BOINC says this: Mon 01 Feb 2016 04:30:38 PM PST | | cc_config.xml not found - using defaults Mon 01 Feb 2016 04:30:38 PM PST | | Starting BOINC client version 7.2.42 for x86_64-pc-linux-gnu Mon 01 Feb 2016 04:30:38 PM PST | | log flags: file_xfer, sched_ops, task Mon 01 Feb 2016 04:30:38 PM PST | | Libraries: libcurl/7.43.0 NSS/3.21 Basic ECC zlib/1.2.8 libidn/1.32 libssh2/1.6.0 nghttp2/1.6.0 Mon 01 Feb 2016 04:30:38 PM PST | | Data directory: /var/lib/boinc Mon 01 Feb 2016 04:30:38 PM PST | | OpenCL CPU: pthread-AMD FX(tm)-8350 Eight-Core Processor (OpenCL driver vendor: The pocl project, driver version 0.12, device version OpenCL 1.2 pocl) Mon 01 Feb 2016 04:30:38 PM PST | | No usable GPUs found Yet, clinfo shows not only the CPU resources (via POCL), but also GPU resources (via MESA): Number of platforms 2 Platform Name Clover Platform Vendor Mesa Platform Version OpenCL 1.1 MESA 11.1.0 Platform Profile FULL_PROFILE Platform Extensions cl_khr_icd Platform Extensions function suffix MESA Platform Name Portable Computing Language Platform Vendor The pocl project Platform Version OpenCL 1.2 pocl 0.12 Platform Profile FULL_PROFILE Platform Extensions cl_khr_icd Platform Extensions function suffix POCL Platform Name Clover Number of devices 2 Device Name AMD PITCAIRN (DRM 2.43.0, LLVM 3.7.0) Device Vendor AMD Device Vendor ID 0x1002 Device Version OpenCL 1.1 MESA 11.1.0 Driver Version 11.1.0 Device OpenCL C Version OpenCL C 1.1 Device Type GPU Device Profile FULL_PROFILE Max compute units 20 Max clock frequency 1050MHz Max work item dimensions 3 Max work item sizes 256x256x256 Max work group size 256 Preferred work group size multiple 64 Preferred / native vector sizes char 16 / 16 short 8 / 8 int 4 / 4 long 2 / 2 half 0 / 0 (n/a) float 4 / 4 double 2 / 2 (cl_khr_fp64) Half-precision Floating-point support (n/a) Single-precision Floating-point support (core) Denormals No Infinity and NANs Yes Round to nearest Yes Round to zero No Round to infinity No IEEE754-2008 fused multiply-add No Support is emulated in software No Correctly-rounded divide and sqrt operations No Double-precision Floating-point support (cl_khr_fp64) Denormals Yes Infinity and NANs Yes Round to nearest Yes Round to zero Yes Round to infinity Yes IEEE754-2008 fused multiply-add Yes Support is emulated in software No Correctly-rounded divide and sqrt operations No Address bits 32, Little-Endian Global memory size 1073741824 (1024MiB) Error Correction support No Max memory allocation 268435456 (256MiB) Unified memory for Host and Device Yes Minimum alignment for any data type 128 bytes Alignment of base address 1024 bits (128 bytes) Global Memory cache type None Image support No Local memory type Local Local memory size 32768 (32KiB) Max constant buffer size 268435456 (256MiB) Max number of constant args 16 Max size of kernel argument 1024 Queue properties Out-of-order execution No Profiling Yes Profiling timer resolution 0ns Execution capabilities Run OpenCL kernels Yes Run native kernels No Device Available Yes Compiler Available Yes Device Extensions cl_khr_global_int32_base_atomics cl_khr_global_int32_extended_atomics cl_khr_local_int32_base_atomics cl_khr_local_int32_extended_atomics cl_khr_byte_addressable_store cl_khr_fp64 Device Name AMD PITCAIRN (DRM 2.43.0, LLVM 3.7.0) Device Vendor AMD Device Vendor ID 0x1002 Device Version OpenCL 1.1 MESA 11.1.0 Driver Version 11.1.0 Device OpenCL C Version OpenCL C 1.1 Device Type GPU Device Profile FULL_PROFILE Max compute units 20 Max clock frequency 1050MHz Max work item dimensions 3 Max work item sizes 256x256x256 Max work group size 256 Preferred work group size multiple 64 Preferred / native vector sizes char 16 / 16 short 8 / 8 int 4 / 4 long 2 / 2 half 0 / 0 (n/a) float 4 / 4 double 2 / 2 (cl_khr_fp64) Half-precision Floating-point support (n/a) Single-precision Floating-point support (core) Denormals No Infinity and NANs Yes Round to nearest Yes Round to zero No Round to infinity No IEEE754-2008 fused multiply-add No Support is emulated in software No Correctly-rounded divide and sqrt operations No Double-precision Floating-point support (cl_khr_fp64) Denormals Yes Infinity and NANs Yes Round to nearest Yes Round to zero Yes Round to infinity Yes IEEE754-2008 fused multiply-add Yes Support is emulated in software No Correctly-rounded divide and sqrt operations No Address bits 32, Little-Endian Global memory size 1073741824 (1024MiB) Error Correction support No Max memory allocation 268435456 (256MiB) Unified memory for Host and Device Yes Minimum alignment for any data type 128 bytes Alignment of base address 1024 bits (128 bytes) Global Memory cache type None Image support No Local memory type Local Local memory size 32768 (32KiB) Max constant buffer size 268435456 (256MiB) Max number of constant args 16 Max size of kernel argument 1024 Queue properties Out-of-order execution No Profiling Yes Profiling timer resolution 0ns Execution capabilities Run OpenCL kernels Yes Run native kernels No Device Available Yes Compiler Available Yes Device Extensions cl_khr_global_int32_base_atomics cl_khr_global_int32_extended_atomics cl_khr_local_int32_base_atomics cl_khr_local_int32_extended_atomics cl_khr_byte_addressable_store cl_khr_fp64 Platform Name Portable Computing Language Number of devices 1 Device Name pthread-AMD FX(tm)-8350 Eight-Core Processor Device Vendor AuthenticAMD Device Vendor ID 0x1002 Device Version OpenCL 1.2 pocl Driver Version 0.12 Device OpenCL C Version OpenCL C 1.2 Device Type CPU, Default Device Profile FULL_PROFILE Max compute units 8 Max clock frequency 4013MHz Device Partition (core) Max number of sub-devices 8 Supported partition types equally, by counts Max work item dimensions 3 Max work item sizes 4096x4096x4096 Max work group size 4096 Preferred work group size multiple 8 Preferred / native vector sizes char 16 / 16 short 8 / 8 int 4 / 4 long 2 / 2 half 8 / 8 (n/a) float 4 / 4 double 2 / 2 (cl_khr_fp64) Half-precision Floating-point support (n/a) Single-precision Floating-point support (core) Denormals No Infinity and NANs Yes Round to nearest Yes Round to zero No Round to infinity No IEEE754-2008 fused multiply-add No Support is emulated in software No Correctly-rounded divide and sqrt operations No Double-precision Floating-point support (cl_khr_fp64) Denormals No Infinity and NANs Yes Round to nearest Yes Round to zero No Round to infinity No IEEE754-2008 fused multiply-add No Support is emulated in software No Correctly-rounded divide and sqrt operations No Address bits 64, Little-Endian Global memory size 33651027968 (31.34GiB) Error Correction support No Max memory allocation 33651027968 (31.34GiB) Unified memory for Host and Device Yes Minimum alignment for any data type 128 bytes Alignment of base address 1024 bits (128 bytes) Global Memory cache type Read/Write Global Memory cache size 16384 Global Memory cache line 64 bytes Image support Yes Max number of samplers per kernel 16 Max size for 1D images from buffer 2103189248 pixels Max 1D or 2D image array size 2048 images Max 2D image size 32768x32768 pixels Max 3D image size 2048x2048x2048 pixels Max number of read image args 128 Max number of write image args 128 Local memory type Global Local memory size 33651027968 (31.34GiB) Max constant buffer size 33651027968 (31.34GiB) Max number of constant args 8 Max size of kernel argument 1024 Queue properties Out-of-order execution No Profiling Yes Profiling timer resolution 0ns Execution capabilities Run OpenCL kernels Yes Run native kernels Yes Prefer user sync for interop Yes printf() buffer size 1048576 (1024KiB) Built-in kernels Device Available Yes Compiler Available Yes Linker Available Yes Device Extensions cl_khr_fp64 cl_khr_byte_addressable_store cl_khr_global_int32_base_atomics cl_khr_global_int32_extended_atomics cl_khr_local_int32_base_atomics cl_khr_local_int32_extended_atomics cl_khr_int64_base_atomics cl_khr_int64_extended_atomics NULL platform behavior clGetPlatformInfo(NULL, CL_PLATFORM_NAME, ...) Clover clGetDeviceIDs(NULL, CL_DEVICE_TYPE_ALL, ...) Success [MESA] clCreateContext(NULL, ...) [default] Success [MESA] clCreateContext(NULL, ...) [other] Success [POCL] clCreateContextFromType(NULL, CL_DEVICE_TYPE_CPU) No devices found in platform clCreateContextFromType(NULL, CL_DEVICE_TYPE_GPU) Success (2) Platform Name Clover Device Name AMD PITCAIRN (DRM 2.43.0, LLVM 3.7.0) Device Name AMD PITCAIRN (DRM 2.43.0, LLVM 3.7.0) 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) Success (2) Platform Name Clover Device Name AMD PITCAIRN (DRM 2.43.0, LLVM 3.7.0) Device Name AMD PITCAIRN (DRM 2.43.0, LLVM 3.7.0) ICD loader properties ICD loader Name OpenCL ICD Loader ICD loader Vendor OCL Icd free software ICD loader Version 2.2.7 ICD loader Profile OpenCL 1.2 So, looking more closely, I see that my GPUs are only OpenCL 1.1 capability, but I think that is the same as before with proprietary drivers. I am very surprised by your statement about OpenCL drivers, but also very pleased and excited. Can you help me get from here to a working configuration? Can you tell what I'm missing from this information? I'm happy to do any testing you ask. |
Send message Joined: 30 May 15 Posts: 265 |
Paul hi there is a small assumption you have tried $ sudo /etc/init.d/boinc-client restart I use the AMD supplied OpenCL but can you 1) post some OpenCL library information - it should be something like $ ldconfig -p | grep -i opencl and 2) version of OS 3) output from xhost Thanks. |
Send message Joined: 8 Dec 13 Posts: 51 |
Thanks for your help! $ sudo /etc/init.d/boinc-client restart Yes, I've been doing that action for a long time, every time I log in. (I also use AMD/ATi as you can see. Proprietary drivers working for you? I'm having a hell of a time getting them to work with kernel 4.3+) I use the AMD supplied OpenCL but can you Sure, no problem. $ ldconfig -p | grep -i opencl libboinc_opencl.so.7 (libc6,x86-64) => /lib64/libboinc_opencl.so.7 libOpenCL.so.1 (libc6,x86-64) => /lib64/libOpenCL.so.1 libOpenCL.so.1 (libc6) => /lib/libOpenCL.so.1 libOpenCL.so (libc6,x86-64) => /lib64/libOpenCL.so libOpenCL.so (libc6) => /lib/libOpenCL.so libMesaOpenCL.so.1 (libc6,x86-64) => /lib64/libMesaOpenCL.so.1 Ooh, never noticed libboinc_opencl before. I tried to find BOINC OpenCL requirements but only found references to proprietary driver instructions and specific projects. This is the sort of thing I was looking for. Is this the latest version for this component? My distribution only has BOINC 7.2; is it worth trying 7.4? $ ls -ltr /usr/lib/*OpenCL* lrwxrwxrwx. 1 root root 23 Dec 16 2013 /usr/lib/libOpenCL.so -> /usr/lib/libOpenCL.so.1* lrwxrwxrwx. 1 root root 18 Jun 17 2015 /usr/lib/libOpenCL.so.1 -> libOpenCL.so.1.0.0* -rwxr-xr-x. 1 root root 118500 Jun 17 2015 /usr/lib/libOpenCL.so.1.0.0* $ ls -ltr /usr/lib64/*OpenCL* lrwxrwxrwx. 1 root root 25 Dec 16 2013 /usr/lib64/libOpenCL.so -> /usr/lib64/libOpenCL.so.1* -rwxr-xr-x. 1 root root 119128 Jun 17 2015 /usr/lib64/libOpenCL.so.1.0.0* lrwxrwxrwx. 1 root root 18 Jun 17 2015 /usr/lib64/libOpenCL.so.1 -> libOpenCL.so.1.0.0* lrwxrwxrwx. 1 root root 22 Jan 13 13:39 /usr/lib64/libMesaOpenCL.so.1 -> libMesaOpenCL.so.1.0.0* -rwxr-xr-x. 1 root root 17043352 Jan 13 13:42 /usr/lib64/libMesaOpenCL.so.1.0.0* 2) version of OS $ uname -a Linux wrangler 4.3.4-300.fc23.x86_64 #1 SMP Mon Jan 25 13:39:23 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux 3) output from xhost $ xhost access control enabled, only authorized clients can connect SI:localuser:boinc SI:localuser:<my username> |
Send message Joined: 20 Nov 12 Posts: 801 |
My distribution only has BOINC 7.2; is it worth trying 7.4? If you can update then preferably to 7.6.22-ish. It's got a bit more error reporting than earlier versions. Also enable <coproc_debug> and repost startup messages. |
Send message Joined: 29 Aug 05 Posts: 15561 |
So, looking more closely, I see that my GPUs are only OpenCL 1.1 capability, but I think that is the same as before with proprietary drivers. I think that depends on the drivers, though. Do you know what model AMD GPU you have? I see it's a Pitcairn, so that's either a HD78xx, HD8870 or one of the R7/R9 low level GPUs. Those are all OpenCL 1.2 capable though, unless the drivers aren't and then they show as OpenCL 1.1 |
Send message Joined: 30 May 15 Posts: 265 |
Proprietary drivers working for you? yes, with Ubuntu 14.04 and also could you... $ ls -ltr /lib/*OpenCL* 2) version of OS Fedora ? If you can get to 7.6.22+ as Juha suggests there is a *lot* better debugging info. |
Send message Joined: 8 Dec 13 Posts: 51 |
Excellent! Thanks for all the suggestions. $ ls -ltr /lib/*OpenCL* lrwxrwxrwx. 1 root root 23 Dec 16 2013 /lib/libOpenCL.so -> /usr/lib/libOpenCL.so.1* lrwxrwxrwx. 1 root root 18 Jun 17 2015 /lib/libOpenCL.so.1 -> libOpenCL.so.1.0.0* -rwxr-xr-x. 1 root root 118500 Jun 17 2015 /lib/libOpenCL.so.1.0.0* lrwxrwxrwx. 1 root root 22 Jan 13 13:25 /lib/libMesaOpenCL.so.1 -> libMesaOpenCL.so.1.0.0* -rwxr-xr-x. 1 root root 17756580 Jan 13 13:27 /lib/libMesaOpenCL.so.1.0.0* (/lib -> /usr/lib64) Yeah, Fedora. Okay! I'll see what I get with 7.6.22. I started using my distro version about 3 years ago, but until then, I was using official release. PITCARN is S. Islands, my card is 7870. It is 1.2 capable according to specs. (But, I don't think my version of Mesa OCL is latest.) PTICARN is supported by crimson and it works under kernel 4.2 and old X11, but wasn't 100% stable. I had trouble installing any driver with 4.3, so, I gave up and thought I would try open-source drivers and wait to see what happens in the next few months. |
Send message Joined: 8 Dec 13 Posts: 51 |
FYI, there isn't any v7.6 for Linux on the download page. I'm downloading 7.4 now, though, but that is development only. |
Send message Joined: 8 Dec 13 Posts: 51 |
Oh right, now I remember. The official releases don't run on Fedora; can't find any libraries. Ugh. Okay, there will be a slight delay while I try to fix this. |
Send message Joined: 8 Dec 13 Posts: 51 |
Okay, so best I can tell, I have to build BOINC myself. That's fine, but I don't know what version to build? I was thinking 7.4.22 because that is the leading version number linked on the download page. But, if you are recommending 7.6.x, can you recommend at version (git tag, specifically) that I should try to build? Hmm, on second though, I guess I'll just try 7.6.22. Might as well if I'm going to the trouble. Let me know if you think I should start somewhere else. |
Send message Joined: 8 Dec 13 Posts: 51 |
I was able to configure the build, but I'm not confident. The build didn't appear to check or opencl stuff, so I'm not sure what to make of it. If you have some thoughts on this please let me know. wxWidgets is a problem, but I think I only need to build the client for this test and I'm sure I can build the wxWidgets libs if I need to. I'm going to start the build now and check in the morning. |
Send message Joined: 8 Dec 13 Posts: 51 |
Oh I almost forgot. In addition to the build not mentioning opencl, the dependencies and build instructions don't mention it either! There were several minor dependencies that were not listed that were caught by ./configure, but I'm very suspicious. You're sure this is supposed to work? |
Send message Joined: 29 Aug 05 Posts: 15561 |
wxWidgets is a problem, but I think I only need to build the client for this test and I'm sure I can build the wxWidgets libs if I need to. wxWidgets is the problem why Berkeley no longer builds BOINC for Linux. Since wxWidgets 3.0 broke for Linux and not all distros out there have since updated to wxWidgets 3.0.1 with a fix, it's impossible to build a working BOINC (Manager) for Linux. And as such the developers are now relying on volunteers and package maintainers to build BOINC for their distros. |
Send message Joined: 20 Nov 12 Posts: 801 |
my card is 7870. It is Umm, just how many cards you have? clinfo says you have two. Don't worry about configure not saying anything about OpenCL. All the GPU libraries are loaded dynamically at runtime. This way the same client can be run on hosts with and without GPUs. |
Send message Joined: 8 Dec 13 Posts: 51 |
Jord, Got it, thanks. Interesting. I'm curious about the details, but I don't think it's important at the moment. I can handle building one extra library. But, correct me if I'm wrong, I don't need the manager to test the client's coproc detection. |
Send message Joined: 8 Dec 13 Posts: 51 |
Umm, just how many cards you have? clinfo says you have two. Just two.
Sweet! But, it seems to be worse...(see next post) |
Send message Joined: 29 Aug 05 Posts: 15561 |
But, correct me if I'm wrong, I don't need the manager to test the client's coproc detection. That's correct, you do not need BOINC Manager for that as it is the client doing the detection. |
Send message Joined: 8 Dec 13 Posts: 51 |
Well, the build was successful, AFAICT. But, when I run it, the coproc detection is even worse with 7.6.23! 7.2.42 from my distribution detects my CPU OpenCL coprocs. But 7.6.23 doesn't. And, it also doesn't detect my GPUs, either. $ boinc_client 05-Feb-2016 13:29:25 [---] Starting BOINC client version 7.6.23 for x86_64-pc-linux-gnu 05-Feb-2016 13:29:25 [---] log flags: file_xfer, sched_ops, task, coproc_debug 05-Feb-2016 13:29:25 [---] Libraries: libcurl/7.43.0 NSS/3.21 Basic ECC zlib/1.2.8 libidn/1.32 libssh2/1.6.0 nghttp2/1.6.0 05-Feb-2016 13:29:25 [---] Data directory: /home/<username>/local/BOINC 05-Feb-2016 13:29:25 [---] [coproc] launching child process at boinc_client 05-Feb-2016 13:29:25 [---] [coproc] relative to directory /home/<username>/local/BOINC 05-Feb-2016 13:29:25 [---] [coproc] with data directory /home/<username>/local/BOINC execv: No such file or directory 05-Feb-2016 13:29:25 [---] GPU detection failed. error code 512 05-Feb-2016 13:29:25 [---] [coproc] read_coproc_info_file() returned error -108 05-Feb-2016 13:29:25 [---] No usable GPUs found (username redacted) Notice the error log that has no header. I'm not sure if this is important or not. Seems like it is since that's just at the point of coproc detection. I did enable coproc_debug, though, so I hope that helps. One problem is that 'make install' failed because it tried to update my /etc/init.d/ files. That's not even how my distribution works, so that would work anyway, but I cannot install this test globally. Why did the install try to do this? I expected the default build to build for local installation, just like the official release shell-extractable packages. I just created BOINC/ and ran boinc_client from there. Is that valid? Can I reconfigure the build to work better for my test? (I think I'll strace this later to see what it tried to run. I don't think the install finished.) I'm pretty far into this, now, so if you have any ideas or want me to try anything, please let me know. |
Copyright © 2024 University of California.
Permission is granted to copy, distribute and/or modify this document
under the terms of the GNU Free Documentation License,
Version 1.2 or any later version published by the Free Software Foundation.