Giter Club home page Giter Club logo

Comments (6)

tomdeakin avatar tomdeakin commented on August 19, 2024

Regarding the build issues, I'm not aware that the NVIDIA drivers support SPIR at all, whereas the Intel drivers do.

We recently merged in #46 which updated the ComputeCpp version to ComputeCpp CE 0.6.1. We've also changed the SYCL API version to 1.2.1.
Maybe this is the root of your trouble?

from babelstream.

jeffhammond avatar jeffhammond commented on August 19, 2024

Updating to 0.6.1 did not fix the GPU problem but it runs on the CPU when I manually select it. I didn't try this before.

I still don't know how to build with ptx64 the way I do for the PRK implementation. It would be nice if BabelStream checked for device.has_extension(cl::sycl::string_class("cl_khr_spir")) if that is required but I can understand why this might be low priority.

GPU failure

jrhammon@klondike:~/Work/OpenCL/BabelStream$ ./sycl-stream --device 0
BabelStream
Version: 3.3
Implementation: SYCL
Running kernels 100 times
Precision: double
Array size: 268.4 MB (=0.3 GB)
Total size: 805.3 MB (=0.8 GB)
Using SYCL device GeForce GTX 960
Driver: 390.30
Reduction kernel config: 32 groups of size 1024
terminate called after throwing an instance of 'cl::sycl::exception'
Aborted (core dumped)

CPU success

$ ./sycl-stream --device 1
BabelStream
Version: 3.3
Implementation: SYCL
Running kernels 100 times
Precision: double
Array size: 268.4 MB (=0.3 GB)
Total size: 805.3 MB (=0.8 GB)
Using SYCL device Intel(R) Core(TM) i7-5960X CPU @ 3.00GHz
Driver: 1.2.0.10
Reduction kernel config: 16 groups of size 8
Function    MBytes/sec  Min (sec)   Max         Average     
Copy        28395.227   0.01891     0.02256     0.01925     
Mul         27793.697   0.01932     0.02707     0.01986     
Add         30163.605   0.02670     0.03339     0.02708     
Triad       30168.183   0.02669     0.02828     0.02697     
Dot         5426.111    0.09894     0.10580     0.10066     
$ ./sycl-stream --list

Devices:
0: GeForce GTX 960
1: Intel(R) Core(TM) i7-5960X CPU @ 3.00GHz
2: Intel(R) Core(TM) i7-5960X CPU @ 3.00GHz
$ /opt/sycl/latest/bin/computecpp_info 
********************************************************************************

ComputeCpp Info (CE 0.6.1)

********************************************************************************

Toolchain information:

GLIBC version: 2.23
GLIBCXX: 20160609
This version of libstdc++ is supported.

********************************************************************************


Device Info:

Discovered 3 devices matching:
  platform    : <any>
  device type : <any>

--------------------------------------------------------------------------------
Device 0:

  Device is supported                     : NO - Device does not support SPIR
  CL_DEVICE_NAME                          : GeForce GTX 960
  CL_DEVICE_VENDOR                        : NVIDIA Corporation
  CL_DRIVER_VERSION                       : 390.30
  CL_DEVICE_TYPE                          : CL_DEVICE_TYPE_GPU 
--------------------------------------------------------------------------------
Device 1:

  Device is supported                     : YES - Tested internally by Codeplay Software Ltd.
  CL_DEVICE_NAME                          : Intel(R) Core(TM) i7-5960X CPU @ 3.00GHz
  CL_DEVICE_VENDOR                        : Intel(R) Corporation
  CL_DRIVER_VERSION                       : 1.2.0.10
  CL_DEVICE_TYPE                          : CL_DEVICE_TYPE_CPU 
--------------------------------------------------------------------------------
Device 2:

  Device is supported                     : YES - Tested internally by Codeplay Software Ltd.
  CL_DEVICE_NAME                          : Intel(R) Core(TM) i7-5960X CPU @ 3.00GHz
  CL_DEVICE_VENDOR                        : Intel(R) Corporation
  CL_DRIVER_VERSION                       : 1.2.0.25
  CL_DEVICE_TYPE                          : CL_DEVICE_TYPE_CPU 

If you encounter problems when using any of these OpenCL devices, please consult
this website for known issues:
https://computecpp.codeplay.com/releases/v0.6.1/platform-support-notes

********************************************************************************

from babelstream.

tomdeakin avatar tomdeakin commented on August 19, 2024

If I understand your issue correctly, it's that you need to build the SYCL BabelStream differently for CPUs and NVIDIA GPUs? The default build with ComputeCpp I'm guessing causes SPIR to be generated, which is not supported by the NVIDIA drivers. But it sounds like there is a way to build with ComputeCpp to output PTX instead.

We do similar specialisation of build options depending on the target for many of the other programming models. Check out the OpenMP.make and OpenACC.make files for example. Perhaps you could implement a similar TARGET option in the SYCL.make to set the correct flags?

from babelstream.

tomdeakin avatar tomdeakin commented on August 19, 2024

Also, notice that the computecpp_info does say that the NVIDIA GPU is not supported.

from babelstream.

jeffhammond avatar jeffhammond commented on August 19, 2024

from babelstream.

tomdeakin avatar tomdeakin commented on August 19, 2024

We've recently updated to follow the SYCL 1.2.1 standard. Is this still an issue for you?

from babelstream.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.