|
| 1 | +##===----------------- _memory.pyx - dpctl module -------*- Cython -*------===## |
| 2 | +## |
| 3 | +## Data Parallel Control (dpCtl) |
| 4 | +## |
| 5 | +## Copyright 2020 Intel Corporation |
| 6 | +## |
| 7 | +## Licensed under the Apache License, Version 2.0 (the "License"); |
| 8 | +## you may not use this file except in compliance with the License. |
| 9 | +## You may obtain a copy of the License at |
| 10 | +## |
| 11 | +## http://www.apache.org/licenses/LICENSE-2.0 |
| 12 | +## |
| 13 | +## Unless required by applicable law or agreed to in writing, software |
| 14 | +## distributed under the License is distributed on an "AS IS" BASIS, |
| 15 | +## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 16 | +## See the License for the specific language governing permissions and |
| 17 | +## limitations under the License. |
| 18 | +## |
| 19 | +##===----------------------------------------------------------------------===## |
| 20 | +## |
| 21 | +## \file |
| 22 | +## This top-level dpctl module. |
| 23 | +## |
| 24 | +##===----------------------------------------------------------------------===## |
1 | 25 | '''
|
2 |
| - Python Data Parallel Processing Library (PyDPPL) |
| 26 | + Data Parallel Control (dpCtl) |
3 | 27 |
|
4 |
| - PyDPPL provides a lightweight Python abstraction over DPC++/SYCL and |
| 28 | + dpCtl provides a lightweight Python abstraction over DPC++/SYCL and |
5 | 29 | OpenCL runtime objects. The DPC++ runtime wrapper objects can be
|
6 | 30 | accessed by importing dpctl. The OpenCL runtime wrapper objects can be
|
7 | 31 | accessed by importing dpctl.ocldrv. The library is in an early-beta
|
8 | 32 | stage of development and not yet ready for production usage.
|
9 | 33 |
|
10 |
| - PyDPPL's intended usage is as a common SYCL interoperability layer for |
| 34 | + dpCtl's intended usage is as a common SYCL interoperability layer for |
11 | 35 | different Python libraries and applications. The OpenCL support inside
|
12 | 36 | PyDPPL is slated to be deprecated and then removed in future releases
|
13 | 37 | of the library.
|
14 | 38 |
|
15 | 39 | Currently, only a small subset of DPC++ runtime objects are exposed
|
16 |
| - through the dpctl module. The main API classes inside the dpctl module are: |
17 |
| -
|
18 |
| - Runtime: The class stores a global SYCL queue and a stack of |
19 |
| - currently activated queues. Runtime provides a special getter |
20 |
| - method to retrieve the currently activated SYCL queue |
21 |
| - as a Py_capsule. |
22 |
| -
|
23 |
| - A single global thread local instance of the Runtime class |
24 |
| - is created on loading the dpctl module for the first time. |
25 |
| -
|
26 |
| - DeviceArray: A DeviceArray object encapsulates a one-dimensional |
27 |
| - cl::sycl::buffer object. A DeviceArray object can be |
28 |
| - created using a NumPy ndarray. The initial implementation |
29 |
| - of DeviceArray follows NumPy's recommended design to create |
30 |
| - a custom array container. DeviceArray does not implement |
31 |
| - the __array_function__ and the __array_ufunc__ interfaces. |
32 |
| - Therefore, DeviceArray does not support NumPy Universal |
33 |
| - functions (ufuncs). The design decision to not support |
34 |
| - ufuncs can be revisited later if we have a need for such |
35 |
| - functionality. For the time being, the class is only meant |
36 |
| - as a data exchange format between Python libraries that |
37 |
| - use SYCL. |
38 |
| -
|
39 |
| - Global data members: |
40 |
| - runtime - An instance of the Runtime class. |
| 40 | + through the dpctl module. The main API classes are defined in the _sycl_core.pyx file. |
41 | 41 |
|
42 | 42 | Please use `pydoc dpctl._sycl_core` to look at the current API for dpctl.
|
43 | 43 |
|
|
0 commit comments