Skip to content

Commit fe4294b

Browse files
Merge remote-tracking branch 'origin/master' into sycl-kernel-api
2 parents 8c20dc4 + 2c86ef6 commit fe4294b

40 files changed

+874
-494
lines changed

.github/workflows/python_style_checks.yml

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -27,18 +27,14 @@ jobs:
2727
# The type of runner that the job will run on
2828
runs-on: ubuntu-latest
2929

30-
strategy:
31-
matrix:
32-
python-version: ['3.10']
33-
3430
# Steps represent a sequence of tasks that will be executed as part of the job
3531
steps:
3632
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
3733
- uses: actions/checkout@v3
3834
# Set up a Python environment for use in actions
3935
- uses: actions/setup-python@v4
4036
with:
41-
python-version: ${{ matrix.python-version }}
37+
python-version: '3.10'
4238

4339
# Run black code formatter
4440
- uses: psf/black@stable
@@ -49,16 +45,12 @@ jobs:
4945
flake8:
5046
runs-on: ubuntu-latest
5147

52-
strategy:
53-
matrix:
54-
python-version: ['3.10']
55-
5648
steps:
5749
- uses: actions/checkout@v3
58-
- name: Set up Python ${{ matrix.python-version }}
50+
- name: Set up Python
5951
uses: actions/setup-python@v4
6052
with:
61-
python-version: ${{ matrix.python-version }}
53+
python-version: '3.10'
6254
- name: Install dependencies
6355
run: |
6456
python -m pip install --upgrade pip

CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,8 @@ include(FetchContent)
3333

3434
FetchContent_Declare(
3535
pybind11
36-
URL https://github.com/pybind/pybind11/archive/refs/tags/v2.10.0.tar.gz
37-
URL_HASH SHA256=eacf582fa8f696227988d08cfc46121770823839fe9e301a20fbce67e7cd70ec
36+
URL https://github.com/pybind/pybind11/archive/refs/tags/v2.10.1.tar.gz
37+
URL_HASH SHA256=111014b516b625083bef701df7880f78c2243835abdb263065b6b59b960b6bad
3838
)
3939
FetchContent_MakeAvailable(pybind11)
4040

dpctl/_version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
# that just contains the computed version number.
77

88
# This file is released into the public domain.
9-
# Generated by versioneer-0.26
9+
# Generated by versioneer-0.28
1010
# https://github.com/python-versioneer/python-versioneer
1111

1212
"""Git implementation of _version.py."""

examples/pybind11/external_usm_allocation/CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@ set(CMAKE_CXX_STANDARD_REQUIRED True)
1313
include(FetchContent)
1414
FetchContent_Declare(
1515
pybind11
16-
URL https://github.com/pybind/pybind11/archive/refs/tags/v2.10.0.tar.gz
17-
URL_HASH SHA256=eacf582fa8f696227988d08cfc46121770823839fe9e301a20fbce67e7cd70ec
16+
URL https://github.com/pybind/pybind11/archive/refs/tags/v2.10.1.tar.gz
17+
URL_HASH SHA256=111014b516b625083bef701df7880f78c2243835abdb263065b6b59b960b6bad
1818
)
1919
FetchContent_MakeAvailable(pybind11)
2020

examples/pybind11/onemkl_gemv/CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@ include(GNUInstallDirs)
1717
include(FetchContent)
1818
FetchContent_Declare(
1919
pybind11
20-
URL https://github.com/pybind/pybind11/archive/refs/tags/v2.10.0.tar.gz
21-
URL_HASH SHA256=eacf582fa8f696227988d08cfc46121770823839fe9e301a20fbce67e7cd70ec
20+
URL https://github.com/pybind/pybind11/archive/refs/tags/v2.10.1.tar.gz
21+
URL_HASH SHA256=111014b516b625083bef701df7880f78c2243835abdb263065b6b59b960b6bad
2222
)
2323
FetchContent_MakeAvailable(pybind11)
2424

examples/pybind11/use_dpctl_syclqueue/CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@ set(CMAKE_CXX_STANDARD_REQUIRED True)
1313
include(FetchContent)
1414
FetchContent_Declare(
1515
pybind11
16-
URL https://github.com/pybind/pybind11/archive/refs/tags/v2.10.0.tar.gz
17-
URL_HASH SHA256=eacf582fa8f696227988d08cfc46121770823839fe9e301a20fbce67e7cd70ec
16+
URL https://github.com/pybind/pybind11/archive/refs/tags/v2.10.1.tar.gz
17+
URL_HASH SHA256=111014b516b625083bef701df7880f78c2243835abdb263065b6b59b960b6bad
1818
)
1919
FetchContent_MakeAvailable(pybind11)
2020

libsyclinterface/helper/source/dpctl_utils_helper.cpp

Lines changed: 21 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@
2424
//===----------------------------------------------------------------------===//
2525

2626
#include "dpctl_utils_helper.h"
27+
#include "Config/dpctl_config.h"
2728
#include <sstream>
2829
#include <string>
2930

@@ -48,9 +49,11 @@ std::string DPCTL_DeviceTypeToStr(info::device_type devTy)
4849
case info::device_type::custom:
4950
ss << "custom";
5051
break;
52+
#if __SYCL_COMPILER_VERSION < __SYCL_COMPILER_2023_SWITCHOVER
5153
case info::device_type::host:
5254
ss << "host";
5355
break;
56+
#endif
5457
default:
5558
ss << "unknown";
5659
}
@@ -90,8 +93,10 @@ backend DPCTL_DPCTLBackendTypeToSyclBackend(DPCTLSyclBackendType BeTy)
9093
switch (BeTy) {
9194
case DPCTLSyclBackendType::DPCTL_CUDA:
9295
return backend::ext_oneapi_cuda;
96+
#if __SYCL_COMPILER_VERSION < __SYCL_COMPILER_2023_SWITCHOVER
9397
case DPCTLSyclBackendType::DPCTL_HOST:
9498
return backend::host;
99+
#endif
95100
case DPCTLSyclBackendType::DPCTL_LEVEL_ZERO:
96101
return backend::ext_oneapi_level_zero;
97102
case DPCTLSyclBackendType::DPCTL_OPENCL:
@@ -108,8 +113,10 @@ DPCTLSyclBackendType DPCTL_SyclBackendToDPCTLBackendType(backend B)
108113
switch (B) {
109114
case backend::ext_oneapi_cuda:
110115
return DPCTLSyclBackendType::DPCTL_CUDA;
116+
#if __SYCL_COMPILER_VERSION < __SYCL_COMPILER_2023_SWITCHOVER
111117
case backend::host:
112118
return DPCTLSyclBackendType::DPCTL_HOST;
119+
#endif
113120
case backend::ext_oneapi_level_zero:
114121
return DPCTLSyclBackendType::DPCTL_LEVEL_ZERO;
115122
case backend::opencl:
@@ -170,9 +177,11 @@ std::string DPCTL_AspectToStr(aspect aspectTy)
170177
{
171178
std::stringstream ss;
172179
switch (aspectTy) {
180+
#if __SYCL_COMPILER_VERSION < __SYCL_COMPILER_2023_SWITCHOVER
173181
case aspect::host:
174182
ss << "host";
175183
break;
184+
#endif
176185
case aspect::cpu:
177186
ss << "cpu";
178187
break;
@@ -242,12 +251,14 @@ std::string DPCTL_AspectToStr(aspect aspectTy)
242251
aspect DPCTL_StrToAspectType(const std::string &aspectTyStr)
243252
{
244253
aspect aspectTy;
245-
if (aspectTyStr == "host") {
246-
aspectTy = aspect::host;
247-
}
248-
else if (aspectTyStr == "cpu") {
254+
if (aspectTyStr == "cpu") {
249255
aspectTy = aspect::cpu;
250256
}
257+
#if __SYCL_COMPILER_VERSION < __SYCL_COMPILER_2023_SWITCHOVER
258+
else if (aspectTyStr == "host") {
259+
aspectTy = aspect::host;
260+
}
261+
#endif
251262
else if (aspectTyStr == "gpu") {
252263
aspectTy = aspect::gpu;
253264
}
@@ -312,8 +323,10 @@ aspect DPCTL_StrToAspectType(const std::string &aspectTyStr)
312323
aspect DPCTL_DPCTLAspectTypeToSyclAspect(DPCTLSyclAspectType AspectTy)
313324
{
314325
switch (AspectTy) {
326+
#if __SYCL_COMPILER_VERSION < __SYCL_COMPILER_2023_SWITCHOVER
315327
case DPCTLSyclAspectType::host:
316328
return aspect::host;
329+
#endif
317330
case DPCTLSyclAspectType::cpu:
318331
return aspect::cpu;
319332
case DPCTLSyclAspectType::gpu:
@@ -360,8 +373,10 @@ aspect DPCTL_DPCTLAspectTypeToSyclAspect(DPCTLSyclAspectType AspectTy)
360373
DPCTLSyclAspectType DPCTL_SyclAspectToDPCTLAspectType(aspect Aspect)
361374
{
362375
switch (Aspect) {
376+
#if __SYCL_COMPILER_VERSION < __SYCL_COMPILER_2023_SWITCHOVER
363377
case aspect::host:
364378
return DPCTLSyclAspectType::host;
379+
#endif
365380
case aspect::cpu:
366381
return DPCTLSyclAspectType::cpu;
367382
case aspect::gpu:
@@ -487,9 +502,11 @@ std::string DPCTL_GetDeviceFilterString(const device &Device)
487502
case backend::opencl:
488503
ss << "opencl";
489504
break;
505+
#if __SYCL_COMPILER_VERSION < __SYCL_COMPILER_2023_SWITCHOVER
490506
case backend::host:
491507
ss << "host";
492508
break;
509+
#endif
493510
default:
494511
ss << "unknown";
495512
};

libsyclinterface/include/Config/dpctl_config.h.in

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,13 @@
2929
#cmakedefine DPCTL_ENABLE_L0_PROGRAM_CREATION \
3030
@DPCTL_ENABLE_L0_PROGRAM_CREATION@
3131

32+
/* Version of SYCL DPC++ 2023 compiler at which transition to SYCL 2020 occurs */
33+
#define __SYCL_COMPILER_2023_SWITCHOVER 20221020L
34+
35+
/* Version of SYCL DPC++ compiler at which info::max_work_item_size was
36+
made templated */
37+
#define __SYCL_COMPILER_MAX_WORK_ITEM_SIZE_THRESHOLD 20220805L
38+
3239
/* The DPCPP version used to build dpctl */
3340
#define DPCTL_DPCPP_VERSION "@IntelSycl_VERSION@"
3441

libsyclinterface/include/Support/CBindingWrapping.h

Lines changed: 0 additions & 55 deletions
This file was deleted.

0 commit comments

Comments
 (0)