OpenCL for CPU Application
log in

Advanced search

Message boards : Unix/Linux : OpenCL for CPU Application

Author Message
Profile Slicker
Volunteer moderator
Project administrator
Project developer
Project tester
Project scientist
Avatar
Send message
Joined: 11 Jun 09
Posts: 2525
Credit: 740,580,099
RAC: 1
Message 14315 - Posted: 26 Jun 2012, 19:11:19 UTC

The OpenCL app for Linux also supports CPU crunching if either the AMD or Intel OpenCL drivers are installed. Since the BOINC client does not report OpenCL for CPUs, the app must be manually installed and the app_info.xml edited appropriately for the number of CPUs/cores.

Step 1.
If you have the Intel OpenCL for CPU drivers installed, you can download: http://boinc.thesonntags.com/collatz/download/OpenCL/collatz_3.11_x86_64-pc-linux-gnu__opencl_intel

If you have the AMD drivers installed you can download: http://boinc.thesonntags.com/collatz/download/OpenCL/collatz_3.11_x86_64-pc-linux-gnu__opencl_amd

Step 2.
You will also need to grab the app_info_intel.xml file and rename it app_info.xml

Step 3.
Edit the app_info.xml file and change the avg_ncpus and max_ncpus values to the total cores/CPUs in your computer. The app will use ALL cores whether or not this number is correct so it really is in your best interest to enter the correct values.

Step 4.
In the app_info.xml file, make sure the cmdline contains "CPU" and "S0". The CPU tells it to use the CPU instead of a GPU. S0 tells it not to sleep while waiting for the kernel to finish since that would be a waste of time since the kernel is running on the CPU.

If there is interest in x86 versions and you would like to help with testing, please let me know. I also plan to build Windows versions if people find this useful.

Finally, I'm also not sure whether this requires the "mt" plan class or not. It isn't multi-threaded like an OpenMP application would normally be as that is all handled by the OpenCL driver. So, if you want to try this out, please let me know how it is working for you.

Dirk Broer
Send message
Joined: 20 Aug 10
Posts: 33
Credit: 177,623,496
RAC: 593,674
Message 17982 - Posted: 3 Dec 2013, 23:03:51 UTC - in response to Message 14315.

The latest BOINC clients do report OpenCL for CPUs, does that mean we will get OpenCL apps for CPU automatically now?
____________

Profile Slicker
Volunteer moderator
Project administrator
Project developer
Project tester
Project scientist
Avatar
Send message
Joined: 11 Jun 09
Posts: 2525
Credit: 740,580,099
RAC: 1
Message 17984 - Posted: 4 Dec 2013, 0:04:59 UTC - in response to Message 17982.

The latest BOINC clients do report OpenCL for CPUs, does that mean we will get OpenCL apps for CPU automatically now?


The short answer is no, not yet.

The long answer is:
Chances are that the plan class name I chose will not match the names the guys from Berkeley chose for BOINC as I'm 0 for 3 on matching so far. That means that it probably won't work without some minor changes.

In addition, the server has to be upgraded as it needs to be able to respond to the client's request for OpenCL for CPU work. That will mean several weeks of work for me to download, merge in the collatz specific changes after figuring out what they changed in this version, compile, deploy to test, test it, make fixes, test again, make fixes, test again, and finally move the new version into the production collatz environment.


Post to thread

Message boards : Unix/Linux : OpenCL for CPU Application


Main page · Your account · Message boards


Copyright © 2018 Jon Sonntag; All rights reserved.