Repository navigation
Add support for events, programs, and kernel submission to dpctl. - #80
Merged
PokhodenkoSA merged 13 commits intoOct 2, 2020
Merged
Conversation
diptorupd
commented
Sep 30, 2020
Contributor
* New dpctl C API wrappers for sycl::event, sycl::kernel and sycl::program.
* Wrappers to create an OpenCL interoperability program from either string
or SPIR-V IL files.
* Support for submitting an interoperability kernel to a sycl::queue. We
support using either a range or an nd_range to submit the kernel.
* Event wait function is now exposed via the C API.
* New test cases for the C API.
* The dpctl Cython wrapper now supports program creation and kernel
submission.
* Other refactoring to standardize function names, attribute names, comments.
diptorupd
requested review from
DrTodd13,
PokhodenkoSA,
oleksandr-pavlyk and
reazulhoque
September 30, 2020 17:41
Contributor
Author
Add new line at end of file.
* Remove empty doxygen comment blocks
* Fix indentation
* Fix grammatical typos
diptorupd
force-pushed
the
feature/program_interfacev2
branch
from
October 1, 2020 02:31
390c747 to
e48ba39
Compare
- The default queue points to a Level-0 device is Level-0 drivers
are installed. However, we always compile our program for OpenCL
and this causes a crash if the test kernels are submitted to the
default queue.
Fixing it by selecting the GPU:0 queue that is known to be an
OpenCL device. A follow up commit will fix this in a proper way.
PokhodenkoSA
reviewed
Oct 1, 2020
| cdef void DPPLQueue_Memcpy (const DPPLSyclQueueRef Q, | ||
| void *Dest, const void *Src, size_t Count) \ | ||
| except + | ||
| void *Dest, const void *Src, size_t Count) |
Contributor
There was a problem hiding this comment.
@diptorupd as I remember you wanted to make Memcpy to return SyclEvent. In the next PR?
PokhodenkoSA
reviewed
Oct 1, 2020
PokhodenkoSA
reviewed
Oct 1, 2020
PokhodenkoSA
reviewed
Oct 1, 2020
| /*! | ||
| * @brief Create a Sycl program from an OpenCL SPIR-V binary file. | ||
| * | ||
| * Sycl 1.2 does expose any method to create a sycl::program from a SPIR-V IL |
Contributor
There was a problem hiding this comment.
Did you mean 'does not expose'?
Contributor
Author
There was a problem hiding this comment.
good catch. Fixed now.
| * OpenCL kernel. | ||
| * | ||
| * The feature to create a Sycl kernel from a SPIR-V IL binary will be available | ||
| * in Sycl 2.0, at which point we may deprecate this function. |
Contributor
There was a problem hiding this comment.
It is better to say, "at which point this function may become deprecated."
Contributor
Author
There was a problem hiding this comment.
I changed the comment. Thanks.
| * @param cgh My Param doc | ||
| * @param Arg My Param doc | ||
| */ | ||
| bool set_kernel_arg (handler &cgh, size_t idx, __dppl_keep void *Arg, |
Contributor
There was a problem hiding this comment.
We will eventually need to support complexes as well.
This is not straightforward with ctypes: https://stackoverflow.com/questions/13373291/complex-number-in-ctypes
So down the road we might just introduce our own scalar type in dpctl.
…ctl into feature/program_interfacev2
This was referenced Oct 3, 2020
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.