WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: opencl  (Read 247 times)

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 9607
opencl
« on: September 22, 2017, 05:41:51 AM »
For those that would like to try opencl, an Xorg-7.7-opencl extension (and deps) has been posted.

There are drivers for amd/radeon (libclc) and intel (beignet), but only the intel drivers have been tested.

If things work, you should see something like this:
Code: [Select]
$ clinfo
Number of platforms                               1
  Platform Name                                   Intel Gen OCL Driver
  Platform Vendor                                 Intel
  Platform Version                                OpenCL 2.0 beignet 1.4 (git-afd050f)
  Platform Profile                                FULL_PROFILE
  Platform 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_3d_image_writes cl_khr_image2d_from_buffer cl_khr_depth_images cl_khr_spir cl_khr_icd cl_intel_accelerator cl_intel_subgroups cl_intel_subgroups_short cl_intel_media_block_io cl_intel_planar_yuv cl_khr_gl_sharing
  Platform Extensions function suffix             Intel

  Platform Name                                   Intel Gen OCL Driver
Number of devices                                 1
  Device Name                                     Intel(R) HD Graphics Haswell Ultrabook GT2 Mobile
  Device Vendor                                   Intel
  Device Vendor ID                                0x8086
  Device Version                                  OpenCL 1.2 beignet 1.4 (git-afd050f)
  Driver Version                                  1.4
  Device OpenCL C Version                         OpenCL C 1.2 beignet 1.4 (git-afd050f)
  Device Type                                     GPU
  Device Available                                Yes
  Device Profile                                  FULL_PROFILE
  Max compute units                               20
  Max clock frequency                             1000MHz
  Device Partition                                (core)
    Max number of sub-devices                     1
    Supported partition types                     None, None, None
  Max work item dimensions                        3
  Max work item sizes                             512x512x512
  Max work group size                             512
  Compiler Available                              Yes
  Linker Available                                Yes
  Preferred work group size multiple              16
...

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 9607
Re: opencl
« Reply #1 on: September 24, 2017, 07:47:13 AM »
pocl - opencl for cpu - also added

If things work, you should see something like this:
Code: [Select]
$ clinfo
Number of platforms                               1
  Platform Name                                   Portable Computing Language
  Platform Vendor                                 The pocl project
  Platform Version                                OpenCL 2.0 pocl 0.14, LLVM 4.0.1
  Platform Profile                                FULL_PROFILE
  Platform Extensions                             cl_khr_icd
  Platform Extensions function suffix             POCL

  Platform Name                                   Portable Computing Language
Number of devices                                 1
  Device Name                                     pthread-Intel(R) Core(TM) i7-4600U CPU @ 2.10GHz
  Device Vendor                                   GenuineIntel
  Device Vendor ID                                0x8086
  Device Version                                  OpenCL 2.0 pocl HSTR: pthread-x86_64-unknown-linux-gnu-x86-64
  Driver Version                                  0.14
  Device OpenCL C Version                         OpenCL C 2.0
  Device Type                                     CPU, Default
  Device Available                                Yes
  Device Profile                                  FULL_PROFILE
  Max compute units                               4
  Max clock frequency                             3300MHz
  Device Partition                                (core)
    Max number of sub-devices                     4
    Supported partition types                     equally, by counts
...

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 9607
Re: opencl
« Reply #2 on: September 28, 2017, 10:37:55 AM »
ocltoys extension added to test opencl

Things work for me with the intel beignet driver on a gpu, but not with the pocl cpu driver.

An issue with llvm >= 3.9 seems to prevent the simultaneous use of more than one opencl driver (i.e. gpu + cpu) and the use of the juliagpu ocl toy.

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 9607
Re: opencl
« Reply #3 on: October 17, 2017, 04:01:56 AM »
hashcat added to benchmark opencl cpu and gpu drivers, cpu:
Code: [Select]
$ hashcat -b -m 1000 --opencl-device-types 1 --opencl-platforms 1 --force
hashcat (pull/1273/head) starting in benchmark mode...

OpenCL Platform #1: The pocl project
====================================
* Device #1: pthread-Intel(R) Core(TM) i7-4600U CPU @ 2.10GHz, 18075/18075 MB allocatable, 4MCU

Hashtype: NTLM

Speed.Dev.#1.....: 75419.5 kH/s (55.55ms)

gpu:
Code: [Select]
$ hashcat -b -m 1000 --opencl-device-types 2 --opencl-platforms 1 --force
hashcat (pull/1273/head) starting in benchmark mode...

OpenCL Platform #1: Intel
=========================
* Device #1: Intel(R) HD Graphics Haswell Ultrabook GT2 Mobile, 1536/2048 MB allocatable, 20MCU

Hashtype: NTLM

Speed.Dev.#1.....:   355.8 MH/s (58.44ms)

..apparently, the closed source intel drivers are faster