Skip to content

Commit cd434c1

Browse files
committed
Merge remote-tracking branch 'origin/sycl' into llvmspirv_pulldown
2 parents afe4c53 + 37916ce commit cd434c1

File tree

77 files changed

+3412
-1756
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

77 files changed

+3412
-1756
lines changed

.github/CODEOWNERS

+2-4
Original file line numberDiff line numberDiff line change
@@ -36,10 +36,8 @@ sycl/doc/extensions/ @intel/dpcpp-specification-reviewers
3636

3737
# Unified Runtime
3838
unified-runtime/ @intel/unified-runtime-reviewers
39-
# TODO: Use specific UR Level Zero adapter team
40-
unified-runtime/*/adapters/level_zero/ @intel/unified-runtime-reviewers
41-
# TODO: Use specific UR OpenCL adapter team
42-
unified-runtime/*/adapters/opencl/ @intel/unified-runtime-reviewers
39+
unified-runtime/*/adapters/level_zero/ @intel/unified-runtime-reviewers-level-zero
40+
unified-runtime/*/adapters/opencl/ @intel/unified-runtime-reviewers-opencl
4341
unified-runtime/*/adapters/cuda/ @intel/llvm-reviewers-cuda
4442
unified-runtime/*/adapters/hip/ @intel/llvm-reviewers-cuda
4543
unified-runtime/*/adapters/native_cpu/ @intel/dpcpp-nativecpu-reviewers

.github/workflows/sycl-detect-changes.yml

+3-1
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,8 @@ jobs:
8282
ur:
8383
- 'unified-runtime/**'
8484
- .github/workflows/ur-*
85+
ur_cuda_adapter:
86+
- 'unified-runtime/source/adapters/cuda/**'
8587
8688
- name: Set output
8789
id: result
@@ -92,7 +94,7 @@ jobs:
9294
return '${{ steps.changes.outputs.changes }}';
9395
}
9496
// Treat everything as changed for huge PRs.
95-
return ["llvm", "llvm_spirv", "clang", "sycl_jit", "xptifw", "libclc", "sycl", "ci", "esimd", "ur"];
97+
return ["llvm", "llvm_spirv", "clang", "sycl_jit", "xptifw", "libclc", "sycl", "ci", "esimd", "ur", "ur_cuda_adapter"];
9698
9799
- run: echo '${{ steps.result.outputs.result }}'
98100

.github/workflows/sycl-linux-build.yml

+25-3
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,10 @@ on:
4646
default: 3
4747
e2e_binaries_artifact:
4848
type: string
49-
required: False
49+
required: false
50+
pack_release:
51+
type: string
52+
required: false
5053

5154
outputs:
5255
build_conclusion:
@@ -100,6 +103,10 @@ on:
100103
options:
101104
- 3
102105

106+
pack_release:
107+
type: string
108+
required: false
109+
103110
permissions: read-all
104111

105112
jobs:
@@ -215,11 +222,26 @@ jobs:
215222
# TODO consider moving this to Dockerfile.
216223
export LD_LIBRARY_PATH=/usr/local/cuda/compat/:/usr/local/cuda/lib64:$LD_LIBRARY_PATH
217224
LIT_OPTS="--allow-empty-runs" LIT_FILTER="e2e_test_requirements" cmake --build $GITHUB_WORKSPACE/build --target check-sycl
218-
- name: Install
225+
- name: Install sycl-toolchain
219226
if: ${{ always() && !cancelled() && steps.build.conclusion == 'success' }}
220-
# TODO replace utility installation with a single CMake target
221227
run: |
222228
cmake --build $GITHUB_WORKSPACE/build --target deploy-sycl-toolchain
229+
230+
- name: Pack toolchain release
231+
if: ${{ always() && !cancelled() && steps.build.conclusion == 'success' && inputs.pack_release == 'true' }}
232+
run: tar -I '${{ steps.artifact_info.outputs.COMPRESS }}' -cf ${{ steps.artifact_info.outputs.ARCHIVE_NAME }} -C $GITHUB_WORKSPACE/build/install .
233+
- name: Upload toolchain release
234+
if: ${{ always() && !cancelled() && steps.build.conclusion == 'success' && inputs.pack_release == 'true' }}
235+
uses: actions/upload-artifact@v4
236+
with:
237+
name: sycl_linux_release
238+
path: ${{ steps.artifact_info.outputs.ARCHIVE_NAME }}
239+
retention-days: ${{ inputs.retention-days }}
240+
241+
- name: Install utilities
242+
if: ${{ always() && !cancelled() && steps.build.conclusion == 'success' }}
243+
# TODO replace utility installation with a single CMake target
244+
run: |
223245
cmake --build $GITHUB_WORKSPACE/build --target utils/FileCheck/install
224246
cmake --build $GITHUB_WORKSPACE/build --target utils/count/install
225247
cmake --build $GITHUB_WORKSPACE/build --target utils/not/install

.github/workflows/sycl-linux-precommit.yml

+21
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,11 @@ on:
2525
- '.github/workflows/trivy.yml'
2626
- 'devops/containers/**'
2727
- 'devops/actions/build_container/**'
28+
- 'unified-runtime/examples/**'
29+
- 'unified-runtime/scripts/**'
30+
- 'unified-runtime/test/**'
31+
- 'unified-runtime/third_party/**'
32+
- 'unified-runtime/tools/**'
2833

2934
concurrency:
3035
# Cancel a currently running workflow from the same PR, branch or tag.
@@ -53,6 +58,22 @@ jobs:
5358
changes: ${{ needs.detect_changes.outputs.filters }}
5459
e2e_binaries_artifact: sycl_e2e_bin_default
5560

61+
# If a PR changes CUDA adapter, run the build on Ubuntu 22.04 as well.
62+
# Ubuntu 22.04 container has CUDA 12.1 installed while Ubuntu 24.0 image
63+
# has CUDA 12.6.1 installed.
64+
# The idea is to ensure that the code works with both CUDA versions.
65+
build_ubuntu2204:
66+
needs: [detect_changes]
67+
if: always() && !cancelled() && contains(needs.detect_changes.outputs.filters, 'ur_cuda_adapter')
68+
uses: ./.github/workflows/sycl-linux-build.yml
69+
with:
70+
build_ref: ${{ github.sha }}
71+
build_cache_root: "/__w/"
72+
build_artifact_suffix: "default"
73+
build_cache_suffix: "default"
74+
build_image: "ghcr.io/intel/llvm/ubuntu2204_build:latest"
75+
changes: ${{ needs.detect_changes.outputs.filters }}
76+
5677
run_prebuilt_e2e_tests:
5778
needs: [build, detect_changes]
5879
if: ${{ always() && !cancelled() && needs.build.outputs.build_conclusion == 'success' }}

.github/workflows/sycl-rel-nightly.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,7 @@ jobs:
214214
image_options: ${{ matrix.image_options }}
215215
target_devices: ${{ matrix.target_devices }}
216216
tests_selector: cts
217-
repo_ref: ${{ github.sha }}
217+
repo_ref: ${{ inputs.testing_branch || 'sycl-rel-6_1_0' }}
218218
devops_ref: sycl
219219
sycl_toolchain_artifact: sycl_linux_default
220220
sycl_toolchain_archive: ${{ needs.ubuntu2204_build.outputs.artifact_archive_name }}

.github/workflows/sycl-windows-precommit.yml

+5
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,11 @@ on:
2424
- '.github/workflows/trivy.yml'
2525
- 'devops/containers/**'
2626
- 'devops/actions/build_container/**'
27+
- 'unified-runtime/examples/**'
28+
- 'unified-runtime/scripts/**'
29+
- 'unified-runtime/test/**'
30+
- 'unified-runtime/third_party/**'
31+
- 'unified-runtime/tools/**'
2732

2833
permissions: read-all
2934

devops/scripts/benchmarks/options.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ class Options:
4040
build_compute_runtime: bool = False
4141
extra_ld_libraries: list[str] = field(default_factory=list)
4242
extra_env_vars: dict = field(default_factory=dict)
43-
compute_runtime_tag: str = "25.05.32567.18"
43+
compute_runtime_tag: str = "25.09.32961.7"
4444
build_igc: bool = False
4545
current_run_name: str = "This PR"
4646
preset: str = "Full"

sycl/include/sycl/detail/type_traits.hpp

+8-4
Original file line numberDiff line numberDiff line change
@@ -24,10 +24,6 @@ template <class T> struct is_fixed_size_group : std::false_type {};
2424

2525
template <class T>
2626
inline constexpr bool is_fixed_size_group_v = is_fixed_size_group<T>::value;
27-
28-
template <typename VecT, typename OperationLeftT, typename OperationRightT,
29-
template <typename> class OperationCurrentT, int... Indexes>
30-
class SwizzleOp;
3127
} // namespace detail
3228

3329
template <int Dimensions> class group;
@@ -154,12 +150,20 @@ template <typename T, size_t N> struct get_elem_type_unqual<marray<T, N>> {
154150
template <typename T, int N> struct get_elem_type_unqual<vec<T, N>> {
155151
using type = T;
156152
};
153+
#if __SYCL_USE_LIBSYCL8_VEC_IMPL
157154
template <typename VecT, typename OperationLeftT, typename OperationRightT,
158155
template <typename> class OperationCurrentT, int... Indexes>
159156
struct get_elem_type_unqual<SwizzleOp<VecT, OperationLeftT, OperationRightT,
160157
OperationCurrentT, Indexes...>> {
161158
using type = typename get_elem_type_unqual<std::remove_cv_t<VecT>>::type;
162159
};
160+
#else
161+
template <bool IsConstVec, typename DataT, int VecSize, int... Indexes>
162+
struct get_elem_type_unqual<detail::hide_swizzle_from_adl::Swizzle<
163+
IsConstVec, DataT, VecSize, Indexes...>> {
164+
using type = DataT;
165+
};
166+
#endif
163167

164168
template <typename ElementType, access::address_space Space,
165169
access::decorated DecorateAddress>

sycl/include/sycl/detail/type_traits/vec_marray_traits.hpp

+29
Original file line numberDiff line numberDiff line change
@@ -32,22 +32,37 @@ template <typename DataT, int NumElements> class __SYCL_EBO vec;
3232
template <typename DataT, std::size_t N> class marray;
3333

3434
namespace detail {
35+
#if __SYCL_USE_LIBSYCL8_VEC_IMPL
3536
template <typename VecT, typename OperationLeftT, typename OperationRightT,
3637
template <typename> class OperationCurrentT, int... Indexes>
3738
class SwizzleOp;
39+
#else
40+
namespace hide_swizzle_from_adl {
41+
template <bool IsConstVec, typename DataT, int VecSize, int... Indexes>
42+
class __SYCL_EBO Swizzle;
43+
}
44+
#endif
3845

3946
// Utility for converting a swizzle to a vector or preserve the type if it isn't
4047
// a swizzle.
4148
template <typename T> struct simplify_if_swizzle {
4249
using type = T;
4350
};
4451

52+
#if __SYCL_USE_LIBSYCL8_VEC_IMPL
4553
template <typename VecT, typename OperationLeftT, typename OperationRightT,
4654
template <typename> class OperationCurrentT, int... Indexes>
4755
struct simplify_if_swizzle<SwizzleOp<VecT, OperationLeftT, OperationRightT,
4856
OperationCurrentT, Indexes...>> {
4957
using type = vec<typename VecT::element_type, sizeof...(Indexes)>;
5058
};
59+
#else
60+
template <bool IsConstVec, typename DataT, int VecSize, int... Indexes>
61+
struct simplify_if_swizzle<detail::hide_swizzle_from_adl::Swizzle<
62+
IsConstVec, DataT, VecSize, Indexes...>> {
63+
using type = vec<DataT, sizeof...(Indexes)>;
64+
};
65+
#endif
5166

5267
template <typename T>
5368
using simplify_if_swizzle_t = typename simplify_if_swizzle<T>::type;
@@ -79,10 +94,17 @@ inline constexpr bool is_valid_type_for_ext_vector_v =
7994
is_valid_type_for_ext_vector<T>::value;
8095

8196
template <typename> struct is_swizzle : std::false_type {};
97+
#if __SYCL_USE_LIBSYCL8_VEC_IMPL
8298
template <typename VecT, typename OperationLeftT, typename OperationRightT,
8399
template <typename> class OperationCurrentT, int... Indexes>
84100
struct is_swizzle<SwizzleOp<VecT, OperationLeftT, OperationRightT,
85101
OperationCurrentT, Indexes...>> : std::true_type {};
102+
#else
103+
template <bool IsConstVec, typename DataT, int VecSize, int... Indexes>
104+
struct is_swizzle<detail::hide_swizzle_from_adl::Swizzle<IsConstVec, DataT,
105+
VecSize, Indexes...>>
106+
: std::true_type {};
107+
#endif
86108
template <typename T> constexpr bool is_swizzle_v = is_swizzle<T>::value;
87109

88110
template <typename T>
@@ -108,11 +130,18 @@ struct num_elements<T __attribute__((ext_vector_type(N)))>
108130
: std::integral_constant<std::size_t, N> {};
109131
#endif
110132
#endif
133+
#if __SYCL_USE_LIBSYCL8_VEC_IMPL
111134
template <typename VecT, typename OperationLeftT, typename OperationRightT,
112135
template <typename> class OperationCurrentT, int... Indexes>
113136
struct num_elements<SwizzleOp<VecT, OperationLeftT, OperationRightT,
114137
OperationCurrentT, Indexes...>>
115138
: std::integral_constant<std::size_t, sizeof...(Indexes)> {};
139+
#else
140+
template <bool IsConstVec, typename DataT, int VecSize, int... Indexes>
141+
struct num_elements<detail::hide_swizzle_from_adl::Swizzle<IsConstVec, DataT,
142+
VecSize, Indexes...>>
143+
: std::integral_constant<std::size_t, sizeof...(Indexes)> {};
144+
#endif
116145

117146
template <typename T>
118147
inline constexpr std::size_t num_elements_v = num_elements<T>::value;

0 commit comments

Comments
 (0)