Giter Site home page Giter Site logo

Comments (3)

germasch avatar germasch commented on June 3, 2024

So I think there's been some subtlety in the type used for sycl, anyway, in that a reference type (queue&) has been used, if I even understood things correctly. It seems to me that sycl could be made to behave more cuda/hip like by having some

struct sycl_stream_t
{
   sycl::queue *q;
}

And that could hopefully be used to eliminate those subtle differences at the interface level?

from gtensor.

bd4 avatar bd4 commented on June 3, 2024

The queue is the gateway to all operations in SYCL, so it can't be null - something needs to intercept the attempt to set a null queue and replace it with the default for that device, or the interface needs to change so setting a null "stream" is not alowed, and resetting to the default is done another way.

from gtensor.

germasch avatar germasch commented on June 3, 2024

Right, the queue can't be null, but a pointer to it can be. So if that's what we're passing from Fortran, we can still use C_NULL_PTR. Currently, we directly use queue&, which never can be officially NULL (though in practice if one passes is from Fortran, with Fortran thinking it's a pointer, it will be null. On the C side, one basically has to go, somewhere,

if (queue_pointer) return *queue; else return default queue;

from gtensor.

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.