Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
86 changes: 84 additions & 2 deletions .github/workflows/sycl-linux-run-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,29 @@ on:
default: ''
required: False

e2e_binaries_artifact:
type: string
default: ''
required: False
e2e_binaries_archive:
type: string
default: ''
required: False
e2e_binaries_decompress_command:
type: string
default: ''
required: False

upload_artifact:
type: string
default: 'false'
build_artifact_suffix:
type: string
default: 'default'
artifact_archive_name:
type: string
default: e2e_binaries.tar.zst

reset_intel_gpu:
type: string
required: False
Expand All @@ -78,6 +101,14 @@ on:
default: 'false'
required: False

outputs:
run_conclusion:
value: ${{ jobs.run.outputs.build_conclusion }}
artifact_archive_name:
value: ${{ jobs.run.outputs.artifact_archive_name }}
artifact_decompress_command:
value: ${{ jobs.run.outputs.artifact_decompress_command }}

workflow_dispatch:
inputs:
runner:
Expand All @@ -87,6 +118,7 @@ on:
- '["amdgpu"]'
- '["Linux", "arc"]'
- '["cts-cpu"]'
- '["Linux", "build"]'
image:
description: |
Use option ending with ":build" for AMDGPU, ":latest" for the rest.
Expand Down Expand Up @@ -142,6 +174,11 @@ on:
options:
- false
- true
upload_artifact:
type: choice
options:
- "false"
- "true"

permissions:
contents: read
Expand All @@ -154,8 +191,31 @@ jobs:
container:
image: ${{ inputs.image }}
options: ${{ inputs.image_options }}
outputs:
run_conclusion: ${{ steps.run.conclusion }}
artifact_archive_name: ${{ steps.artifact_info.outputs.ARCHIVE_NAME }}
artifact_decompress_command: ${{ steps.artifact_info.outputs.DECOMPRESS }}
env: ${{ fromJSON(inputs.env) }}
steps:
- name: Deduce artifact archive params
if: inputs.upload_artifact == 'true'
id: artifact_info
run: |
NAME="${{inputs.artifact_archive_name}}"
if [ -z "$NAME" ]; then
NAME=e2e_binaries.tar.zst
fi
echo ARCHIVE_NAME="$NAME" >> $GITHUB_OUTPUT
if [ "${NAME}" != "${NAME%.tar.gz}" ]; then
echo COMPRESS="gzip" >> $GITHUB_OUTPUT
echo DECOMPRESS="gunzip" >> $GITHUB_OUTPUT
elif [ "${NAME}" != "${NAME%.tar.zst}" ]; then
echo COMPRESS="zstd -9" >> $GITHUB_OUTPUT
echo DECOMPRESS="zstd" >> $GITHUB_OUTPUT
else
echo "Unsupported extension"
exit 1
fi
- name: Reset Intel GPU
if: inputs.reset_intel_gpu == 'true'
run: |
Expand Down Expand Up @@ -270,8 +330,20 @@ jobs:
cat /usr/local/lib/igc/IGCTAG.txt
fi

- name: Download E2E Binaries
if: inputs.e2e_binaries_artifact != '' && github.event_name != 'workflow_run'
uses: actions/download-artifact@v4
with:
name: ${{ inputs.e2e_binaries_artifact }}
- name: Extract/Setup E2E Binaries
if: inputs.e2e_binaries_artifact != ''
run: |
mkdir build-e2e
tar -I '${{ inputs.e2e_binaries_decompress_command }}' -xf ${{ inputs.e2e_binaries_archive }} -C build-e2e
rm -f ${{ inputs.e2e_binaries_artifact }}

- name: Deduce E2E CMake options
if: inputs.tests_selector == 'e2e'
if: inputs.tests_selector == 'e2e' && inputs.e2e_binaries_artifact == ''
id: cmake_opts
shell: bash
env:
Expand All @@ -281,7 +353,7 @@ jobs:
echo "opts=$CMAKE_EXTRA_ARGS" >> $GITHUB_OUTPUT
fi
- name: Configure E2E tests
if: inputs.tests_selector == 'e2e'
if: inputs.tests_selector == 'e2e' && inputs.e2e_binaries_artifact == ''
run: |
cmake -GNinja -B./build-e2e -S./llvm/sycl/test-e2e -DSYCL_TEST_E2E_TARGETS="${{ inputs.target_devices }}" -DCMAKE_CXX_COMPILER="$(which clang++)" -DLLVM_LIT="$PWD/llvm/llvm/utils/lit/lit.py" ${{ steps.cmake_opts.outputs.opts }}
- name: SYCL End-to-end tests
Expand Down Expand Up @@ -375,3 +447,13 @@ jobs:
grep 'exit code: [^0]' -r logs >> $GITHUB_STEP_SUMMARY

exit $ret
- name: Pack e2e binaries
if: ${{ always() && !cancelled() && inputs.upload_artifact == 'true'}}
run: tar -I '${{ steps.artifact_info.outputs.COMPRESS }}' -cf ${{ steps.artifact_info.outputs.ARCHIVE_NAME }} -C ./build-e2e .
- name: Upload e2e binaries
if: ${{ always() && !cancelled() && inputs.upload_artifact == 'true'}}
uses: actions/upload-artifact@v4
with:
name: sycl_e2e_bin_${{ inputs.build_artifact_suffix }}
path: ${{ steps.artifact_info.outputs.ARCHIVE_NAME }}
retention-days: ${{ inputs.retention-days }}
83 changes: 83 additions & 0 deletions .github/workflows/sycl-nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,89 @@ jobs:

artifact_archive_name: sycl_linux_shared.tar.zst

ubuntu2204_split_test_build:
needs: [ubuntu2204_build]
if: ${{ always() && !cancelled() && needs.ubuntu2204_build.outputs.build_conclusion == 'success' }}
uses: ./.github/workflows/sycl-linux-run-tests.yml
with:
name: Build e2e tests
runner: '["Linux", "build"]'
image: ghcr.io/intel/llvm/ubuntu2204_intel_drivers:alldeps
image_options: -u 1001
target_devices: opencl:cpu
tests_selector: e2e
extra_lit_opts: --param test-mode=build-only
ref: ${{ github.sha }}
merge_ref: ''
sycl_toolchain_artifact: sycl_linux_default
sycl_toolchain_archive: ${{ needs.ubuntu2204_build.outputs.artifact_archive_name }}
sycl_toolchain_decompress_command: ${{ needs.ubuntu2204_build.outputs.artifact_decompress_command }}
upload_artifact: 'true'

ubuntu2204_split_test_run:
needs: [ubuntu2204_build, ubuntu2204_split_test_build]
if: ${{ always() && !cancelled() && needs.ubuntu2204_build.outputs.build_conclusion == 'success' }}
strategy:
fail-fast: false
matrix:
include:
- name: Intel L0 GPU
runner: '["Linux", "gen12"]'
image: ghcr.io/intel/llvm/ubuntu2204_intel_drivers:latest
image_options: -u 1001 --device=/dev/dri -v /dev/dri/by-path:/dev/dri/by-path --privileged --cap-add SYS_ADMIN
target_devices: level_zero:gpu
reset_intel_gpu: true
tests_selector: e2e
extra_lit_opts: --param gpu-intel-gen12=True

- name: Intel OCL GPU
runner: '["Linux", "gen12"]'
image: ghcr.io/intel/llvm/ubuntu2204_intel_drivers:latest
image_options: -u 1001 --device=/dev/dri -v /dev/dri/by-path:/dev/dri/by-path --privileged --cap-add SYS_ADMIN
target_devices: opencl:gpu
reset_intel_gpu: true
tests_selector: e2e
extra_lit_opts: --param gpu-intel-gen12=True

- name: OCL CPU (AMD)
runner: '["Linux", "amdgpu"]'
image: ghcr.io/intel/llvm/ubuntu2204_intel_drivers:latest
image_options: -u 1001
target_devices: opencl:cpu
tests_selector: e2e

- name: OCL CPU (Intel/GEN12)
runner: '["Linux", "gen12"]'
image: ghcr.io/intel/llvm/ubuntu2204_intel_drivers:latest
image_options: -u 1001 --privileged --cap-add SYS_ADMIN
target_devices: opencl:cpu
tests_selector: e2e

- name: OCL CPU (Intel/Arc)
runner: '["Linux", "arc"]'
image: ghcr.io/intel/llvm/ubuntu2204_intel_drivers:latest
image_options: -u 1001
target_devices: opencl:cpu
tests_selector: e2e
uses: ./.github/workflows/sycl-linux-run-tests.yml
with:
name: ${{ matrix.name }}
runner: ${{ matrix.runner }}
image: ${{ matrix.image }}
image_options: ${{ matrix.image_options }}
target_devices: ${{ matrix.target_devices }}
tests_selector: ${{ matrix.tests_selector }}
extra_lit_opts: --param test-mode=run-only ${{ matrix.extra_lit_opts }}
reset_intel_gpu: ${{ matrix.reset_intel_gpu }}
ref: ${{ github.sha }}
merge_ref: ''
sycl_toolchain_artifact: sycl_linux_default
sycl_toolchain_archive: ${{ needs.ubuntu2204_build.outputs.artifact_archive_name }}
sycl_toolchain_decompress_command: ${{ needs.ubuntu2204_build.outputs.artifact_decompress_command }}
e2e_binaries_artifact: sycl_e2e_bin_default
e2e_binaries_archive: ${{ needs.ubuntu2204_split_test_build.outputs.artifact_archive_name }}
e2e_binaries_decompress_command: ${{ needs.ubuntu2204_split_test_build.outputs.artifact_decompress_command }}

ubuntu2204_test:
needs: [ubuntu2204_build]
if: ${{ always() && !cancelled() && needs.ubuntu2204_build.outputs.build_conclusion == 'success' }}
Expand Down
Loading