Skip to content

Commit 7b0a45a

Browse files
committed
Merge branch 'main' into sean/unique-addr-mode-per-dim-adapters
2 parents 4749e99 + 79c28d0 commit 7b0a45a

File tree

151 files changed

+3260
-6025
lines changed

Some content is hidden

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

151 files changed

+3260
-6025
lines changed

.github/workflows/bandit.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,17 @@ concurrency:
77
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
88
cancel-in-progress: true
99

10+
permissions:
11+
contents: read
12+
1013
jobs:
1114
linux:
1215
name: Bandit
1316
runs-on: ubuntu-latest
1417

1518
steps:
1619
- name: Clone the git repo
17-
uses: actions/checkout@v3
20+
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
1821

1922
- name: Install pip packages
2023
run: pip install -r third_party/requirements.txt

.github/workflows/cmake.yml

Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,9 @@ concurrency:
66
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
77
cancel-in-progress: true
88

9+
permissions:
10+
contents: read
11+
912
jobs:
1013
ubuntu-build:
1114
name: Build - Ubuntu
@@ -36,7 +39,7 @@ jobs:
3639
runs-on: ${{matrix.os}}
3740

3841
steps:
39-
- uses: actions/checkout@v3
42+
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
4043

4144
- name: Install apt packages
4245
run: |
@@ -110,7 +113,7 @@ jobs:
110113

111114
- name: Test
112115
working-directory: ${{github.workspace}}/build
113-
run: ctest -C ${{matrix.build_type}} --output-on-failure -L "python|umf|loader|validation|tracing|unit|urtrace"
116+
run: ctest -C ${{matrix.build_type}} --output-on-failure -L "umf|loader|validation|tracing|unit|urtrace"
114117

115118
fuzztest-build:
116119
name: Build and run quick fuzztest scenarios
@@ -122,7 +125,7 @@ jobs:
122125
runs-on: 'ubuntu-22.04'
123126

124127
steps:
125-
- uses: actions/checkout@v3
128+
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
126129

127130
- name: Install pip packages
128131
run: pip install -r third_party/requirements.txt
@@ -174,7 +177,7 @@ jobs:
174177
runs-on: ${{matrix.adapter.name}}
175178

176179
steps:
177-
- uses: actions/checkout@v3
180+
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
178181

179182
- name: Install pip packages
180183
run: pip install -r third_party/requirements.txt
@@ -240,13 +243,13 @@ jobs:
240243
runs-on: ${{matrix.adapter.name}}
241244

242245
steps:
243-
- uses: actions/checkout@v3
246+
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
244247

245248
- name: Install pip packages
246249
run: pip install -r third_party/requirements.txt
247250

248251
- name: Init conda env
249-
uses: conda-incubator/setup-miniconda@v2
252+
uses: conda-incubator/setup-miniconda@9f54435e0e72c53962ee863144e47a4b094bfd35 # v2.3.0
250253
with:
251254
miniconda-version: "latest"
252255
activate-environment: examples
@@ -306,9 +309,9 @@ jobs:
306309
runs-on: ${{matrix.os}}
307310

308311
steps:
309-
- uses: actions/checkout@v3
312+
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
310313

311-
- uses: actions/setup-python@v4
314+
- uses: actions/setup-python@65d7f2d534ac1bc67fcd62888c5f4f3d2cb2b236 # v4.7.1
312315
with:
313316
python-version: 3.9
314317

@@ -346,7 +349,7 @@ jobs:
346349

347350
- name: Test
348351
working-directory: ${{github.workspace}}/build
349-
run: ctest -C ${{matrix.build_type}} --output-on-failure -L "python|umf|loader|validation|tracing|unit|urtrace"
352+
run: ctest -C ${{matrix.build_type}} --output-on-failure -L "umf|loader|validation|tracing|unit|urtrace"
350353

351354

352355
macos-build:
@@ -357,9 +360,9 @@ jobs:
357360
runs-on: ${{matrix.os}}
358361

359362
steps:
360-
- uses: actions/checkout@v3
363+
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
361364

362-
- uses: actions/setup-python@v4
365+
- uses: actions/setup-python@65d7f2d534ac1bc67fcd62888c5f4f3d2cb2b236 # v4.7.1
363366
with:
364367
python-version: 3.9
365368

.github/workflows/codeql.yml

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,9 @@ concurrency:
66
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
77
cancel-in-progress: true
88

9+
permissions:
10+
contents: read
11+
912
jobs:
1013
analyze-ubuntu:
1114
name: Analyze on Ubuntu
@@ -18,10 +21,10 @@ jobs:
1821

1922
steps:
2023
- name: Checkout repository
21-
uses: actions/checkout@v3
24+
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
2225

2326
- name: Initialize CodeQL
24-
uses: github/codeql-action/init@v2
27+
uses: github/codeql-action/init@1500a131381b66de0c52ac28abb13cd79f4b7ecc # v2.22.12
2528
with:
2629
languages: cpp, python
2730

@@ -35,7 +38,7 @@ jobs:
3538
run: cmake --build ${{github.workspace}}/build -j $(nproc)
3639

3740
- name: Perform CodeQL Analysis
38-
uses: github/codeql-action/analyze@v2
41+
uses: github/codeql-action/analyze@1500a131381b66de0c52ac28abb13cd79f4b7ecc # v2.22.12
3942

4043
analyze-windows:
4144
name: Analyze on Windows
@@ -48,10 +51,10 @@ jobs:
4851

4952
steps:
5053
- name: Checkout repository
51-
uses: actions/checkout@v3
54+
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
5255

5356
- name: Initialize CodeQL
54-
uses: github/codeql-action/init@v2
57+
uses: github/codeql-action/init@1500a131381b66de0c52ac28abb13cd79f4b7ecc # v2.22.12
5558
with:
5659
languages: cpp, python
5760

@@ -65,4 +68,4 @@ jobs:
6568
run: cmake --build ${{github.workspace}}/build -j $(nproc) --config Release
6669

6770
- name: Perform CodeQL Analysis
68-
uses: github/codeql-action/analyze@v2
71+
uses: github/codeql-action/analyze@1500a131381b66de0c52ac28abb13cd79f4b7ecc # v2.22.12

.github/workflows/coverage.yml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,9 @@ name: Coverage
22

33
on: [push, pull_request]
44

5+
permissions:
6+
contents: read
7+
58
jobs:
69
ubuntu-build:
710
name: Build - Ubuntu
@@ -16,7 +19,7 @@ jobs:
1619
runs-on: ${{matrix.os}}
1720

1821
steps:
19-
- uses: actions/checkout@v3
22+
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
2023

2124
- name: Install apt packages
2225
run: |
@@ -65,14 +68,14 @@ jobs:
6568

6669
- name: Test
6770
working-directory: ${{github.workspace}}/build
68-
run: ctest -C ${{matrix.build_type}} --output-on-failure -L "python|umf|loader|validation|tracing|unit|urtrace"
71+
run: ctest -C ${{matrix.build_type}} --output-on-failure -L "umf|loader|validation|tracing|unit|urtrace"
6972

7073
- name: Quick Coverage Info
7174
working-directory: ${{github.workspace}}/build
7275
run: ctest -T Coverage
7376

7477
- name: Upload coverage to Codecov
75-
uses: codecov/codecov-action@v3
78+
uses: codecov/codecov-action@eaaf4bedf32dbdc6b720b63067d99c4d77d6047d # v3.1.4
7679
with:
7780
gcov: true
7881
gcov_include: source

.github/workflows/coverity.yml

Lines changed: 23 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,10 @@ name: coverity-unified-runtime
99
# It runs static analysis build - Coverity. It requires special token (set in CI's secret).
1010

1111
on:
12-
push:
13-
branches: ["main"]
1412
workflow_dispatch:
13+
schedule:
14+
# Run every day at 22:00 UTC
15+
- cron: '0 22 * * *'
1516

1617
env:
1718
WORKDIR: ${{ github.workspace }}
@@ -22,20 +23,37 @@ env:
2223
COVERITY_SCAN_BRANCH_PATTERN: "main"
2324
TRAVIS_BRANCH: ${{ github.ref_name }}
2425

26+
permissions:
27+
contents: read
28+
2529
jobs:
2630
linux:
2731
name: Coverity
28-
runs-on: ubuntu-latest
32+
runs-on: coverity
2933

3034
steps:
3135
- name: Clone the git repo
32-
uses: actions/checkout@v3
36+
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
3337

3438
- name: Install pip packages
3539
run: pip install -r third_party/requirements.txt
3640

3741
- name: Configure CMake
38-
run: cmake -B $WORKDIR/build -DUR_ENABLE_TRACING=ON -DUR_DEVELOPER_MODE=ON -DUR_BUILD_TESTS=ON -DUMF_ENABLE_POOL_TRACKING=ON
42+
run: >
43+
cmake
44+
-B $WORKDIR/build
45+
-DUR_ENABLE_TRACING=ON
46+
-DUR_DEVELOPER_MODE=ON
47+
-DUR_BUILD_TESTS=ON
48+
-DUMF_ENABLE_POOL_TRACKING=ON
49+
-DUR_FORMAT_CPP_STYLE=ON
50+
-DCMAKE_BUILD_TYPE=Debug
51+
-DUR_BUILD_ADAPTER_L0=ON
52+
-DUR_BUILD_ADAPTER_CUDA=ON
53+
-DCUDA_CUDA_LIBRARY=/usr/local/cuda/lib64/stubs/libcuda.so
54+
-DUR_BUILD_ADAPTER_NATIVE_CPU=ON
55+
-DUR_BUILD_ADAPTER_HIP=ON
56+
-DUR_BUILD_ADAPTER_OPENCL=ON
3957
4058
- name: Run Coverity
4159
run: |

.github/workflows/docs.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,9 @@ jobs:
2626
runs-on: ubuntu-latest
2727
steps:
2828
- name: Checkout
29-
uses: actions/checkout@v3
29+
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
3030

31-
- uses: actions/setup-python@v4
31+
- uses: actions/setup-python@65d7f2d534ac1bc67fcd62888c5f4f3d2cb2b236 # v4.7.1
3232
with:
3333
python-version: 3.9
3434

@@ -41,14 +41,14 @@ jobs:
4141
run: python3 -m pip install -r third_party/requirements.txt
4242

4343
- name: Setup Pages
44-
uses: actions/configure-pages@v2
44+
uses: actions/configure-pages@c5a3e1159e0cbdf0845eb8811bd39e39fc3099c2 # v2.1.3
4545

4646
- name: Build Documentation
4747
working-directory: ${{github.workspace}}/scripts
4848
run: python3 run.py --core
4949

5050
- name: Upload artifact
51-
uses: actions/upload-pages-artifact@v1
51+
uses: actions/upload-pages-artifact@84bb4cd4b733d5c320c9c9cfbc354937524f4d64 # v1.0.10
5252
with:
5353
path: ${{github.workspace}}/docs/html
5454

@@ -62,4 +62,4 @@ jobs:
6262
steps:
6363
- name: Deploy to GitHub Pages
6464
id: deployment
65-
uses: actions/deploy-pages@v1
65+
uses: actions/deploy-pages@f27bcc15848fdcdcc02f01754eb838e44bcf389b # v1.2.9

.github/workflows/e2e_nightly.yml

Lines changed: 19 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,17 @@ on:
55
# Run every day at 23:00 UTC
66
- cron: '0 23 * * *'
77

8+
permissions:
9+
contents: read
10+
811
jobs:
912
e2e-build-hw:
1013
name: Build SYCL, UR, run E2E
1114
strategy:
1215
matrix:
1316
adapter: [
14-
{name: CUDA}
17+
{name: CUDA, str_name: cuda, prefix: "ext_oneapi_", config: "--cuda --hip", unit: "gpu"},
18+
{name: OPENCL, str_name: opencl, prefix: "", config: "", unit: "cpu"}
1519
]
1620
build_type: [Release]
1721
compiler: [{c: clang, cxx: clang++}]
@@ -28,12 +32,12 @@ jobs:
2832
rm -rf ./* || true
2933
3034
- name: Checkout UR
31-
uses: actions/checkout@v4
35+
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
3236
with:
3337
path: ur-repo
3438

3539
- name: Checkout SYCL
36-
uses: actions/checkout@v4
40+
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
3741
with:
3842
repository: intel/llvm
3943
ref: sycl
@@ -59,12 +63,18 @@ jobs:
5963
run: LD_LIBRARY_PATH=${{github.workspace}}/dpcpp_compiler/lib
6064
cmake --build ${{github.workspace}}/ur-repo/build -j $(nproc)
6165

62-
- name: Set env vars & pre setup
66+
- name: Set prefer UR
67+
run: echo "SYCL_PREFER_UR=1" >> $GITHUB_ENV
68+
69+
- name: Set CUDA env vars
70+
if: matrix.adapter.name == 'CUDA'
6371
run: |
64-
echo "SYCL_PREFER_UR=1" >> $GITHUB_ENV
6572
echo "CUDA_LIB_PATH=/usr/local/cuda/lib64/stubs" >> $GITHUB_ENV
6673
echo "LD_LIBRARY_PATH=/usr/local/cuda/compat/:/usr/local/cuda/lib64:$LD_LIBRARY_PATH" >> $GITHUB_ENV
67-
source /opt/intel/oneapi/setvars.sh
74+
75+
- name: Run pre setup
76+
run: |
77+
source /opt/intel/oneapi/setvars.sh --force
6878
sycl-ls
6979
7080
- name: Configure SYCL
@@ -73,7 +83,7 @@ jobs:
7383
-t ${{matrix.build_type}}
7484
-o ${{github.workspace}}/sycl_build
7585
--cmake-gen "Unix Makefiles"
76-
--ci-defaults --cuda --hip
86+
--ci-defaults ${{matrix.adapter.config}}
7787
--cmake-opt="-DLLVM_INSTALL_UTILS=ON"
7888
--cmake-opt="-DSYCL_PI_TESTS=OFF"
7989
--cmake-opt=-DCMAKE_C_COMPILER_LAUNCHER=ccache
@@ -91,7 +101,7 @@ jobs:
91101
- name: Swap UR loader and adapters
92102
run: |
93103
cp ${{github.workspace}}/ur-repo/build/lib/libur_loader.so* ${{github.workspace}}/sycl_build/lib/
94-
cp ${{github.workspace}}/ur-repo/build/lib/libur_adapter_cuda.so* ${{github.workspace}}/sycl_build/lib/
104+
cp ${{github.workspace}}/ur-repo/build/lib/libur_adapter_${{matrix.adapter.str_name}}.so* ${{github.workspace}}/sycl_build/lib/
95105
96106
- name: Set additional env. vars
97107
run: |
@@ -110,7 +120,7 @@ jobs:
110120
-GNinja
111121
-B ${{github.workspace}}/build-e2e/
112122
-S ${{github.workspace}}/sycl-repo/sycl/test-e2e/
113-
-DSYCL_TEST_E2E_TARGETS="ext_oneapi_cuda:gpu"
123+
-DSYCL_TEST_E2E_TARGETS="${{matrix.adapter.prefix}}${{matrix.adapter.str_name}}:${{matrix.adapter.unit}}"
114124
-DCMAKE_CXX_COMPILER="$(which clang++)"
115125
-DLLVM_LIT="${{github.workspace}}/sycl-repo/llvm/utils/lit/lit.py"
116126

.github/workflows/nightly.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,9 @@ on:
55
# Run every day at 23:00 UTC
66
- cron: '0 23 * * *'
77

8+
permissions:
9+
contents: read
10+
811
jobs:
912
long-fuzz-test:
1013
name: Run long fuzz tests
@@ -16,7 +19,7 @@ jobs:
1619
runs-on: 'ubuntu-22.04'
1720

1821
steps:
19-
- uses: actions/checkout@v3
22+
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
2023

2124
- name: Install pip packages
2225
run: pip install -r third_party/requirements.txt

0 commit comments

Comments
 (0)