Skip to content

Commit c82fa86

Browse files
committed
remove remaining references to dpctl.program
1 parent af0d7f8 commit c82fa86

10 files changed

Lines changed: 18 additions & 23 deletions

File tree

dpctl/_sycl_queue.pxd

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ from ._backend cimport (
3232
from ._sycl_context cimport SyclContext
3333
from ._sycl_device cimport SyclDevice
3434
from ._sycl_event cimport SyclEvent
35-
from .program._program cimport SyclKernel
35+
from .compiler._compiler cimport SyclKernel
3636

3737

3838
cdef public api class _SyclQueue [

dpctl/_sycl_queue.pyx

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -383,7 +383,7 @@ kernel_arg_type = _kernel_arg_type()
383383
cdef class SyclKernelSubmitError(Exception):
384384
"""
385385
A ``SyclKernelSubmitError`` exception is raised when
386-
the provided :class:`.program.SyclKernel` could not be
386+
the provided :class:`.compiler.SyclKernel` could not be
387387
submitted to the :class:`.SyclQueue`.
388388
389389
"""
@@ -1178,10 +1178,10 @@ cdef class SyclQueue(_SyclQueue):
11781178
list dEvents=None
11791179
):
11801180
"""
1181-
Asynchronously submit :class:`dpctl.program.SyclKernel` for execution.
1181+
Asynchronously submit :class:`dpctl.compiler.SyclKernel` for execution.
11821182
11831183
Args:
1184-
kernel (dpctl.program.SyclKernel):
1184+
kernel (dpctl.compiler.SyclKernel):
11851185
SYCL kernel object
11861186
args (List[object]):
11871187
List of kernel arguments
@@ -1339,10 +1339,10 @@ cdef class SyclQueue(_SyclQueue):
13391339
list dEvents=None
13401340
):
13411341
"""
1342-
Submit :class:`dpctl.program.SyclKernel` for execution.
1342+
Submit :class:`dpctl.compiler.SyclKernel` for execution.
13431343
13441344
Args:
1345-
kernel (dpctl.program.SyclKernel):
1345+
kernel (dpctl.compiler.SyclKernel):
13461346
SYCL kernel object
13471347
args (List[object]):
13481348
List of kernel arguments

dpctl/apis/include/dpctl_capi.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,8 @@
4545
#include "dpctl/_sycl_queue_api.h"
4646
#include "dpctl/memory/_memory.h"
4747
#include "dpctl/memory/_memory_api.h"
48-
#include "dpctl/program/_program.h"
49-
#include "dpctl/program/_program_api.h"
48+
#include "dpctl/compiler/_compiler.h"
49+
#include "dpctl/compiler/_compiler_api.h"
5050

5151
// clang-format on
5252

@@ -66,6 +66,6 @@ static inline void import_dpctl(void)
6666
import_dpctl___sycl_event();
6767
import_dpctl___sycl_queue();
6868
import_dpctl__memory___memory();
69-
import_dpctl__program___program();
69+
import_dpctl__compiler___compiler();
7070
return;
7171
}

dpctl/compiler/CMakeLists.txt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
21
file(GLOB _cython_sources *.pyx)
32
foreach(_cy_file ${_cython_sources})
43
get_filename_component(_trgt ${_cy_file} NAME_WLE)

dpctl/compiler/_compiler.pxd

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,3 @@ cpdef create_kernel_bundle_from_spirv (
6868
unicode copts=*,
6969
list specializations=*,
7070
)
71-
cpdef create_program_from_source (SyclQueue q, unicode source, unicode copts=*)
72-
cpdef create_program_from_spirv (
73-
SyclQueue q, const unsigned char[:] IL, unicode copts=*
74-
)

dpctl/compiler/_compiler.pyx

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -186,14 +186,14 @@ cdef class SyclKernel:
186186

187187
cdef api DPCTLSyclKernelRef SyclKernel_GetKernelRef(SyclKernel ker):
188188
""" C-API function to access opaque kernel reference from
189-
Python object of type :class:`dpctl.program.SyclKernel`.
189+
Python object of type :class:`dpctl.compiler.SyclKernel`.
190190
"""
191191
return ker.get_kernel_ref()
192192

193193

194194
cdef api SyclKernel SyclKernel_Make(DPCTLSyclKernelRef KRef, const char *name):
195195
"""
196-
C-API function to create :class:`dpctl.program.SyclKernel`
196+
C-API function to create :class:`dpctl.compiler.SyclKernel`
197197
instance from opaque sycl kernel reference.
198198
"""
199199
cdef DPCTLSyclKernelRef copied_KRef = DPCTLKernel_Copy(KRef)
@@ -252,14 +252,14 @@ cdef api DPCTLSyclKernelBundleRef SyclKernelBundle_GetKernelBundleRef(
252252
SyclKernelBundle kb
253253
):
254254
""" C-API function to access opaque kernel bundle reference from
255-
Python object of type :class:`dpctl.program.SyclKernelBundle`.
255+
Python object of type :class:`dpctl.compiler.SyclKernelBundle`.
256256
"""
257257
return kb.get_kernel_bundle_ref()
258258

259259

260260
cdef api SyclKernelBundle SyclKernelBundle_Make(DPCTLSyclKernelBundleRef KBRef):
261261
"""
262-
C-API function to create :class:`dpctl.program.SyclKernelBundle`
262+
C-API function to create :class:`dpctl.compiler.SyclKernelBundle`
263263
instance from opaque ``sycl::kernel_bundle<sycl::bundle_state::executable>``
264264
reference.
265265
"""
@@ -272,7 +272,7 @@ cdef class SpecializationConstant:
272272
SpecializationConstant(spec_id, *args)
273273
274274
Python class representing SYCL specialization constants that can be used
275-
when creating a :class:`dpctl.program.SyclKernelBundle` from SPIR-V.
275+
when creating a :class:`dpctl.compiler.SyclKernelBundle` from SPIR-V.
276276
277277
There are multiple ways to create a :class:`.SpecializationConstant`:
278278

dpctl/tests/test_raw_kernel_arg.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ def launch_raw_arg_kernel(raw):
6969
spirv_file = get_spirv_abspath("raw-arg-kernel.spv")
7070
with open(spirv_file, "br") as spv:
7171
spv_bytes = spv.read()
72-
kb = dpctl.program.create_kernel_bundle_from_spirv(q, spv_bytes)
72+
kb = dpctl.compiler.create_kernel_bundle_from_spirv(q, spv_bytes)
7373
kernel = kb.get_sycl_kernel("__sycl_kernel_raw_arg_kernel")
7474
local_size = 16
7575
global_size = local_size * 8

dpctl/tests/test_work_group_memory.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ def test_submit_work_group_memory():
6262
spirv_file = get_spirv_abspath("work-group-memory-kernel.spv")
6363
with open(spirv_file, "br") as spv:
6464
spv_bytes = spv.read()
65-
kb = dpctl.program.create_kernel_bundle_from_spirv(q, spv_bytes)
65+
kb = dpctl.compiler.create_kernel_bundle_from_spirv(q, spv_bytes)
6666
kernel = kb.get_sycl_kernel("__sycl_kernel_local_mem_kernel")
6767
local_size = 16
6868
global_size = local_size * 8

dpctl/tests/test_work_group_memory_opencl.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ def test_submit_work_group_memory_opencl():
4545
except dpctl.SyclQueueCreationError:
4646
pytest.skip("OpenCL queue could not be created")
4747

48-
kb = dpctl.program.create_kernel_bundle_from_source(q, ocl_kernel_src)
48+
kb = dpctl.compiler.create_kernel_bundle_from_source(q, ocl_kernel_src)
4949
kernel = kb.get_sycl_kernel("local_mem_kernel")
5050
local_size = 16
5151
global_size = local_size * 8

examples/pybind11/use_dpctl_sycl_kernel/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
cmake_minimum_required(VERSION 3.21...3.27 FATAL_ERROR)
22

33
project(use_queue_device VERSION 0.1 LANGUAGES CXX
4-
DESCRIPTION "Example of using dpctl.program.SyclKernel <-> sycl::kernel type casting")
4+
DESCRIPTION "Example of using dpctl.compiler.SyclKernel <-> sycl::kernel type casting")
55

66
set(DPCTL_CMAKE_MODULES_PATH "${CMAKE_SOURCE_DIR}/../../../cmake")
77
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${DPCTL_CMAKE_MODULES_PATH})

0 commit comments

Comments
 (0)