From ab17254cb0f5472c11a20c797acd064ca7f7b69d Mon Sep 17 00:00:00 2001 From: "Li, Ian" Date: Fri, 13 Sep 2024 13:42:09 -0700 Subject: [PATCH] Take benchmarking out of sycl-linux-run-tests --- .github/workflows/sycl-linux-benchmark.yml | 242 +++++++++++++-------- .github/workflows/sycl-linux-build.yml | 24 ++ .github/workflows/sycl-linux-precommit.yml | 222 ++++++++++++------- .github/workflows/sycl-linux-run-tests.yml | 39 +--- 4 files changed, 321 insertions(+), 206 deletions(-) diff --git a/.github/workflows/sycl-linux-benchmark.yml b/.github/workflows/sycl-linux-benchmark.yml index de2c5b64e82f..090c2b39c5f2 100644 --- a/.github/workflows/sycl-linux-benchmark.yml +++ b/.github/workflows/sycl-linux-benchmark.yml @@ -125,19 +125,134 @@ permissions: contents: read jobs: - build: - if: inputs.sycl_toolchain_artifact == '' + check_build: + name: Build (if no sycl artifact provided) uses: ./.github/workflows/sycl-linux-build.yml with: build_ref: ${{ github.sha }} merge_ref: '' build_cache_root: "/__w/" - build_artifact_suffix: "default" - build_cache_suffix: "default" + build_artifact_suffix: "default_benchmark" + build_cache_suffix: "default_benchmark" build_image: ${{ inputs.image }} + skip_build: ${{ inputs.sycl_toolchain_archive != '' }} + skip_reason: "SYCL toolchain artifact already provided, no build necessary" - run_archive: - if: inputs.sycl_toolchain_archive != '' +# run_archive: +# if: inputs.sycl_toolchain_archive != '' +# runs-on: ${{ fromJSON(inputs.runner) }} +# container: +# image: ${{ inputs.image }} +# options: ${{ inputs.image_options }} +# env: ${{ fromJSON(inputs.env) }} +# steps: +# - name: Reset GPU +# if: inputs.reset_gpu == 'true' +# run: | +# sudo mount -t debugfs none /sys/kernel/debug +# sudo bash -c 'echo 1 > /sys/kernel/debug/dri/0/i915_wedged' +# - uses: actions/checkout@v4 +# with: +# ref: ${{ inputs.ref }} +# sparse-checkout: | +# devops +# - name: Register cleanup after job is finished +# uses: ./devops/actions/cleanup +# - name: Install drivers +# if: inputs.install_drivers == 'true' +# env: +# GITHUB_TOKEN: ${{ github.token }} +# run: | +# if [ "${{ inputs.use_dev_igc }}" = "true" ]; then +# # If libllvm14 is already installed (dev igc docker), still return true. +# sudo apt-get install -yqq libllvm14 || true; +# fi +# sudo -E bash devops/scripts/install_drivers.sh llvm/devops/dependencies.json ${{ inputs.use_dev_igc == 'true' && 'llvm/devops/dependencies-igc-dev.json --use-dev-igc' || '' }} --all +# - name: Source OneAPI TBB vars.sh +# shell: bash +# run: | +# # https://github.com/actions/runner/issues/1964 prevents us from using +# # the ENTRYPOINT in the image. +# env | sort > env_before +# if [ -e /runtimes/oneapi-tbb/env/vars.sh ]; then +# source /runtimes/oneapi-tbb/env/vars.sh; +# elif [ -e /opt/runtimes/oneapi-tbb/env/vars.sh ]; then +# source /opt/runtimes/oneapi-tbb/env/vars.sh; +# else +# echo "no TBB vars in /opt/runtimes or /runtimes"; +# fi +# env | sort > env_after +# comm -13 env_before env_after >> $GITHUB_ENV +# rm env_before env_after +# +# - name: Download SYCL toolchain +# if: inputs.sycl_toolchain_artifact != '' && github.event_name != 'workflow_run' +# uses: actions/download-artifact@v4 +# with: +# name: ${{ inputs.sycl_toolchain_artifact }} +# - name: Download SYCL toolchain [workflow_run] +# if: inputs.sycl_toolchain_artifact != '' && github.event_name == 'workflow_run' +# uses: actions/github-script@v7 +# with: +# script: | +# const name = '${{ inputs.sycl_toolchain_artifact }}' +# let allArtifacts = await github.rest.actions.listWorkflowRunArtifacts({ +# owner: context.repo.owner, +# repo: context.repo.repo, +# run_id: context.payload.workflow_run.id, +# }); +# let matchArtifact = allArtifacts.data.artifacts.filter((artifact) => { +# return artifact.name == name +# })[0]; +# let download = await github.rest.actions.downloadArtifact({ +# owner: context.repo.owner, +# repo: context.repo.repo, +# artifact_id: matchArtifact.id, +# archive_format: 'zip', +# }); +# let fs = require('fs'); +# fs.writeFileSync(`${process.env.GITHUB_WORKSPACE}/` + name + '.zip', Buffer.from(download.data)); +# - name: Unzip artifact [workflow_run] +# if: inputs.sycl_toolchain_artifact != '' && github.event_name == 'workflow_run' +# run: | +# unzip ${{ inputs.sycl_toolchain_artifact }}.zip +# rm ${{ inputs.sycl_toolchain_artifact }}.zip +# - name: Extract/Setup SYCL toolchain +# if: inputs.sycl_toolchain_artifact != '' +# run: | +# mkdir toolchain +# tar -I '${{ inputs.sycl_toolchain_decompress_command }}' -xf ${{ inputs.sycl_toolchain_archive }} -C toolchain +# rm -f ${{ inputs.sycl_toolchain_archive }} +# echo PATH=$PWD/toolchain/bin/:$PATH >> $GITHUB_ENV +# echo LD_LIBRARY_PATH=$PWD/toolchain/lib/:$LD_LIBRARY_PATH >> $GITHUB_ENV +# - run: which clang++ sycl-ls +# - run: sycl-ls --verbose +# - run: SYCL_UR_TRACE=1 sycl-ls +# - run: | +# if [ -f /usr/local/lib/igc/IGCTAG.txt ]; then +# cat /usr/local/lib/igc/IGCTAG.txt +# fi +# +# - name: Run compute-benchmarks +# id: run_benchmarks +# if: success() +# run: | +# whereis clang++ +# whereis sycl-ls +# clang++ --version +# ls +# export CMPLR_ROOT=$PWD/toolchain +# ./devops/scripts/benchmarking/benchmark.sh +# # - name: Upload sycl-bench microbenchmark results +# # if: inputs.tests_selector == 'benchmark' && steps.run_benchmarks.outcome == 'success' +# # uses: actions/upload-artifact@v4 +# # with: +# # name: sycl_benchmark_res_${{ steps.run_benchmarks.outputs.TIMESTAMP }} +# # path: ${{ steps.run_benchmarks.outputs.BENCHMARK_RESULTS }} +# # retention-days: 7 + + run_benchmarks: + needs: [ check_build ] runs-on: ${{ fromJSON(inputs.runner) }} container: image: ${{ inputs.image }} @@ -184,16 +299,16 @@ jobs: rm env_before env_after - name: Download SYCL toolchain - if: inputs.sycl_toolchain_artifact != '' && github.event_name != 'workflow_run' + if: github.event_name != 'workflow_run' uses: actions/download-artifact@v4 with: - name: ${{ inputs.sycl_toolchain_artifact }} + name: ${{ inputs.sycl_toolchain_artifact || 'sycl_linux_benchmark_ver' }} - name: Download SYCL toolchain [workflow_run] - if: inputs.sycl_toolchain_artifact != '' && github.event_name == 'workflow_run' + if: && github.event_name == 'workflow_run' uses: actions/github-script@v7 with: script: | - const name = '${{ inputs.sycl_toolchain_artifact }}' + const name = '${{ inputs.sycl_toolchain_artifact || 'sycl_linux_benchmark_ver' }}' let allArtifacts = await github.rest.actions.listWorkflowRunArtifacts({ owner: context.repo.owner, repo: context.repo.repo, @@ -211,18 +326,19 @@ jobs: let fs = require('fs'); fs.writeFileSync(`${process.env.GITHUB_WORKSPACE}/` + name + '.zip', Buffer.from(download.data)); - name: Unzip artifact [workflow_run] - if: inputs.sycl_toolchain_artifact != '' && github.event_name == 'workflow_run' + if: github.event_name == 'workflow_run' run: | - unzip ${{ inputs.sycl_toolchain_artifact }}.zip - rm ${{ inputs.sycl_toolchain_artifact }}.zip + unzip ${{ inputs.sycl_toolchain_artifact || 'sycl_linux_benchmark_ver' }}.zip + rm ${{ inputs.sycl_toolchain_artifact || 'sycl_linux_benchmark_ver' }}.zip - name: Extract/Setup SYCL toolchain - if: inputs.sycl_toolchain_artifact != '' run: | mkdir toolchain - tar -I '${{ inputs.sycl_toolchain_decompress_command }}' -xf ${{ inputs.sycl_toolchain_archive }} -C toolchain - rm -f ${{ inputs.sycl_toolchain_archive }} + tar -I '${{ inputs.sycl_toolchain_decompress_command || needs.check_build.outputs.artifact_decompress_command }}' \ + -xf ${{ inputs.sycl_toolchain_archive || needs.check_build.outputs.artifact_archive_name }} -C toolchain + rm -f ${{ inputs.sycl_toolchain_archive || needs.check_build.outputs.artifact_archive_name }} echo PATH=$PWD/toolchain/bin/:$PATH >> $GITHUB_ENV echo LD_LIBRARY_PATH=$PWD/toolchain/lib/:$LD_LIBRARY_PATH >> $GITHUB_ENV + - run: ls - run: which clang++ sycl-ls - run: sycl-ls --verbose - run: SYCL_UR_TRACE=1 sycl-ls @@ -231,6 +347,10 @@ jobs: cat /usr/local/lib/igc/IGCTAG.txt fi + # - name: Install deps + # if: success() + # run: | + # sudo apt install -y ssh - name: Run compute-benchmarks id: run_benchmarks if: success() @@ -241,80 +361,26 @@ jobs: ls export CMPLR_ROOT=$PWD/toolchain ./devops/scripts/benchmarking/benchmark.sh - # - name: Upload sycl-bench microbenchmark results - # if: inputs.tests_selector == 'benchmark' && steps.run_benchmarks.outcome == 'success' - # uses: actions/upload-artifact@v4 - # with: - # name: sycl_benchmark_res_${{ steps.run_benchmarks.outputs.TIMESTAMP }} - # path: ${{ steps.run_benchmarks.outputs.BENCHMARK_RESULTS }} - # retention-days: 7 - - run_build: - needs: [build] - runs-on: ${{ fromJSON(inputs.runner) }} - container: - image: ${{ inputs.image }} - options: ${{ inputs.image_options }} - env: ${{ fromJSON(inputs.env) }} - steps: - - name: Reset GPU - if: inputs.reset_gpu == 'true' - run: | - sudo mount -t debugfs none /sys/kernel/debug - sudo bash -c 'echo 1 > /sys/kernel/debug/dri/0/i915_wedged' - - uses: actions/checkout@v4 - with: - ref: ${{ inputs.ref }} - sparse-checkout: | - devops - - name: Register cleanup after job is finished - uses: ./devops/actions/cleanup - - name: Install drivers - if: inputs.install_drivers == 'true' - env: - GITHUB_TOKEN: ${{ github.token }} - run: | - if [ "${{ inputs.use_dev_igc }}" = "true" ]; then - # If libllvm14 is already installed (dev igc docker), still return true. - sudo apt-get install -yqq libllvm14 || true; - fi - sudo -E bash devops/scripts/install_drivers.sh llvm/devops/dependencies.json ${{ inputs.use_dev_igc == 'true' && 'llvm/devops/dependencies-igc-dev.json --use-dev-igc' || '' }} --all - - name: Source OneAPI TBB vars.sh - shell: bash - run: | - # https://github.com/actions/runner/issues/1964 prevents us from using - # the ENTRYPOINT in the image. - env | sort > env_before - if [ -e /runtimes/oneapi-tbb/env/vars.sh ]; then - source /runtimes/oneapi-tbb/env/vars.sh; - elif [ -e /opt/runtimes/oneapi-tbb/env/vars.sh ]; then - source /opt/runtimes/oneapi-tbb/env/vars.sh; - else - echo "no TBB vars in /opt/runtimes or /runtimes"; - fi - env | sort > env_after - comm -13 env_before env_after >> $GITHUB_ENV - rm env_before env_after - - - run: ls - - run: which clang++ sycl-ls - - run: sycl-ls --verbose - - run: SYCL_UR_TRACE=1 sycl-ls - - run: | - if [ -f /usr/local/lib/igc/IGCTAG.txt ]; then - cat /usr/local/lib/igc/IGCTAG.txt - fi - - - name: Run compute-benchmarks - id: run_benchmarks + exit $? + - name: Push compute-benchmarks if: success() + env: + SSH_KEY: ${{secrets.ACTIONS_DEPLOY_KEY}} run: | - whereis clang++ - whereis sycl-ls - clang++ --version - ls - export CMPLR_ROOT=$PWD/toolchain - ./devops/scripts/benchmarking/benchmark.sh + mkdir -p ~/.ssh + echo "$SSH_KEY" > ~/.ssh/id_rsa + chmod 600 ~/.ssh/id_rsa + echo "###" + echo "$(ssh-agent -s)" + echo "###" + eval "$(ssh-agent -s)" + ssh-add -k ~/.ssh/id_rsa + cd llvm-ci-perf-results + git config --global user.name "iclsrc" + git config --global user.email "ia.compiler.tools.git@intel.com" + git add . + git commit -m "Update results" + git push # - name: Upload sycl-bench microbenchmark results # if: inputs.tests_selector == 'benchmark' && steps.run_benchmarks.outcome == 'success' # uses: actions/upload-artifact@v4 diff --git a/.github/workflows/sycl-linux-build.yml b/.github/workflows/sycl-linux-build.yml index 17dcc83aeb43..e0d390dd3dba 100644 --- a/.github/workflows/sycl-linux-build.yml +++ b/.github/workflows/sycl-linux-build.yml @@ -50,6 +50,18 @@ on: description: 'Artifacts retention period' type: string default: 3 + skip_build: + description: | + Build is skipped if set to true. This is used to implement building + based on a condition, as github currently does not provide a way to + have dynamic `needs` dependencies between jobs. + type: boolean + default: false + skip_reason: + description: | + Reason for skipping the build. + type: string + default: "inputs.skip-reason set to true." outputs: build_conclusion: @@ -109,6 +121,7 @@ jobs: build: name: Build + LIT runs-on: [Linux, build] + if: ${{ inputs.skip_build != 'true' }} container: image: ${{ inputs.build_image }} options: -u 1001:1001 @@ -242,3 +255,14 @@ jobs: name: sycl_linux_${{ inputs.build_artifact_suffix }} path: ${{ steps.artifact_info.outputs.ARCHIVE_NAME }} retention-days: ${{ inputs.retention-days }} + + skip_build: + name: Build skipped (${{ inputs.skip_reason }}) + runs-on: [Linux, aux-tasks] + if: ${{ inputs.skip_build == 'true' }} + outputs: + build_conclusion: "skipped" + artifact_archive_name: "" + artifact_decompress_command: "" + steps: + - run: echo "Build skipped -- ${{ inputs.skip_reason }}." \ No newline at end of file diff --git a/.github/workflows/sycl-linux-precommit.yml b/.github/workflows/sycl-linux-precommit.yml index 7fe0f6e868ad..0d5d7f97a142 100644 --- a/.github/workflows/sycl-linux-precommit.yml +++ b/.github/workflows/sycl-linux-precommit.yml @@ -47,29 +47,146 @@ jobs: build_cache_suffix: "default" changes: ${{ needs.detect_changes.outputs.filters }} - determine_arc_tests: - name: Decide which Arc tests to run - needs: [build, detect_changes] - if: ${{ always() && !cancelled() && needs.build.outputs.build_conclusion == 'success' }} - runs-on: [Linux, aux-tasks] - timeout-minutes: 3 - outputs: - arc_tests: ${{ steps.arc_tests.outputs.arc_tests }} - steps: - - name: Determine Arc tests - id: arc_tests - run: | - if [ "${{ contains(needs.detect_changes.outputs.filters, 'devigccfg') }}" == "true" ]; then - echo 'arc_tests="(ESIMD|InvokeSimd|Matrix)/"' >> "$GITHUB_OUTPUT" - elif [ "${{ contains(needs.detect_changes.outputs.filters, 'drivers') }}" == "true" ]; then - echo 'arc_tests=""' >> "$GITHUB_OUTPUT" - elif [ "${{ contains(needs.detect_changes.outputs.filters, 'esimd') }}" == "true" ]; then - echo 'arc_tests="(ESIMD|InvokeSimd|Matrix)/"' >> "$GITHUB_OUTPUT" - else - echo 'arc_tests="Matrix/"' >> "$GITHUB_OUTPUT" - fi - test: - needs: [build, detect_changes, determine_arc_tests] +# determine_arc_tests: +# name: Decide which Arc tests to run +# needs: [build, detect_changes] +# if: ${{ always() && !cancelled() && needs.build.outputs.build_conclusion == 'success' }} +# runs-on: [Linux, aux-tasks] +# timeout-minutes: 3 +# outputs: +# arc_tests: ${{ steps.arc_tests.outputs.arc_tests }} +# steps: +# - name: Determine Arc tests +# id: arc_tests +# run: | +# if [ "${{ contains(needs.detect_changes.outputs.filters, 'devigccfg') }}" == "true" ]; then +# echo 'arc_tests="(ESIMD|InvokeSimd|Matrix)/"' >> "$GITHUB_OUTPUT" +# elif [ "${{ contains(needs.detect_changes.outputs.filters, 'drivers') }}" == "true" ]; then +# echo 'arc_tests=""' >> "$GITHUB_OUTPUT" +# elif [ "${{ contains(needs.detect_changes.outputs.filters, 'esimd') }}" == "true" ]; then +# echo 'arc_tests="(ESIMD|InvokeSimd|Matrix)/"' >> "$GITHUB_OUTPUT" +# else +# echo 'arc_tests="Matrix/"' >> "$GITHUB_OUTPUT" +# fi +# test: +# needs: [build, detect_changes, determine_arc_tests] +# if: ${{ always() && !cancelled() && needs.build.outputs.build_conclusion == 'success' }} +# strategy: +# fail-fast: false +# matrix: +# include: +# - name: NVIDIA/CUDA +# runner: '["Linux", "cuda"]' +# image: ghcr.io/intel/llvm/ubuntu2204_build:latest +# image_options: -u 1001 --gpus all --cap-add SYS_ADMIN +# target_devices: ext_oneapi_cuda:gpu +# - name: Intel +# runner: '["Linux", "gen12"]' +# image: ghcr.io/intel/llvm/ubuntu2204_intel_drivers:latest +# image_options: -u 1001 --device=/dev/dri --privileged --cap-add SYS_ADMIN +# target_devices: level_zero:gpu;opencl:gpu;opencl:cpu +# reset_intel_gpu: true +# install_drivers: ${{ contains(needs.detect_changes.outputs.filters, 'drivers') }} +# extra_lit_opts: --param gpu-intel-gen12=True +# - name: E2E tests on Intel Arc A-Series Graphics +# runner: '["Linux", "arc"]' +# image: ghcr.io/intel/llvm/ubuntu2204_intel_drivers:latest +# image_options: -u 1001 --device=/dev/dri --privileged --cap-add SYS_ADMIN +# target_devices: level_zero:gpu;opencl:gpu +# reset_intel_gpu: true +# install_drivers: ${{ contains(needs.detect_changes.outputs.filters, 'drivers') }} +# extra_lit_opts: --param matrix-xmx8=True --param gpu-intel-dg2=True +# env: '{"LIT_FILTER":${{ needs.determine_arc_tests.outputs.arc_tests }} }' +# - name: E2E tests with dev igc on Intel Arc A-Series Graphics +# runner: '["Linux", "arc"]' +# image: ghcr.io/intel/llvm/ubuntu2204_intel_drivers:devigc +# image_options: -u 1001 --device=/dev/dri --privileged --cap-add SYS_ADMIN +# target_devices: level_zero:gpu;opencl:gpu +# reset_intel_gpu: true +# install_drivers: >- +# ${{ contains(needs.detect_changes.outputs.filters, 'drivers') || +# contains(needs.detect_changes.outputs.filters, 'devigccfg') }} +# use_dev_igc: ${{ contains(needs.detect_changes.outputs.filters, 'devigccfg') }} +# extra_lit_opts: --param matrix-xmx8=True --param gpu-intel-dg2=True +# env: '{"LIT_FILTER":${{ needs.determine_arc_tests.outputs.arc_tests }} }' +# # Run only if the PR does not have the 'ci-no-devigc' label. +# skip_run: ${{ contains(github.event.pull_request.labels.*.name, 'ci-no-devigc') }} +# +# 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 }} +# reset_intel_gpu: ${{ matrix.reset_intel_gpu }} +# install_drivers: ${{ matrix.install_drivers }} +# use_dev_igc: ${{ matrix.use_dev_igc }} +# extra_lit_opts: ${{ matrix.extra_lit_opts }} +# env: ${{ matrix.env || '{}' }} +# skip_run: ${{ matrix.skip_run || 'false' }} +# tests_selector: "benchmark" +# +# ref: ${{ github.sha }} +# merge_ref: '' +# +# sycl_toolchain_artifact: sycl_linux_default +# sycl_toolchain_archive: ${{ needs.build.outputs.artifact_archive_name }} +# sycl_toolchain_decompress_command: ${{ needs.build.outputs.artifact_decompress_command }} +# +# +# test-perf: +# needs: [build, detect_changes] +# if: | +# always() && !cancelled() +# && needs.build.outputs.build_conclusion == 'success' +# && (contains(github.event.pull_request.labels.*.name, 'run-perf-tests') +# || contains(needs.detect_changes.outputs.filters, 'perf-tests')) +# strategy: +# fail-fast: false +# matrix: +# include: +# - name: Intel GEN12 Graphics system +# runner: '["Linux", "gen12"]' +# image: ghcr.io/intel/llvm/ubuntu2204_intel_drivers:latest +# image_extra_opts: --device=/dev/dri +# reset_intel_gpu: true +# - name: Intel Arc A-Series Graphics system +# runner: '["Linux", "arc"]' +# image: ghcr.io/intel/llvm/ubuntu2204_intel_drivers:latest +# image_extra_opts: --device=/dev/dri +# reset_intel_gpu: true +# - name: AMD system +# runner: '["Linux", "amdgpu"]' +# image: ghcr.io/intel/llvm/ubuntu2204_build:latest +# image_extra_opts: --device=/dev/dri --device=/dev/kfd +# extra_cmake_args: -DHIP_PLATFORM="AMD" -DAMD_ARCH="gfx1031" +# - name: CUDA system +# runner: '["Linux", "cuda"]' +# image: ghcr.io/intel/llvm/ubuntu2204_build:latest +# image_extra_opts: --gpus all +# uses: ./.github/workflows/sycl-linux-run-tests.yml +# with: +# name: Perf tests on ${{ matrix.name }} +# runner: ${{ matrix. runner }} +# image: ${{ matrix.image }} +# image_options: -u 1001 --privileged --cap-add SYS_ADMIN ${{ matrix.image_extra_opts }} +# target_devices: all +# reset_intel_gpu: ${{ matrix.reset_intel_gpu }} +# +# env: '{"LIT_FILTER":"PerformanceTests/"}' +# extra_lit_opts: -a -j 1 --param enable-perf-tests=True +# extra_cmake_args: ${{ matrix.extra_cmake_args }} +# +# ref: ${{ github.sha }} +# merge_ref: '' +# +# sycl_toolchain_artifact: sycl_linux_default +# sycl_toolchain_archive: ${{ needs.build.outputs.artifact_archive_name }} +# sycl_toolchain_decompress_command: ${{ needs.build.outputs.artifact_decompress_command }} + + benchmark: + needs: [build, detect_changes ] if: ${{ always() && !cancelled() && needs.build.outputs.build_conclusion == 'success' }} strategy: fail-fast: false @@ -87,7 +204,6 @@ jobs: target_devices: level_zero:gpu;opencl:gpu;opencl:cpu reset_intel_gpu: true install_drivers: ${{ contains(needs.detect_changes.outputs.filters, 'drivers') }} - extra_lit_opts: --param gpu-intel-gen12=True # - name: E2E tests on Intel Arc A-Series Graphics # runner: '["Linux", "arc"]' # image: ghcr.io/intel/llvm/ubuntu2204_intel_drivers:latest @@ -95,7 +211,6 @@ jobs: # target_devices: level_zero:gpu;opencl:gpu # reset_intel_gpu: true # install_drivers: ${{ contains(needs.detect_changes.outputs.filters, 'drivers') }} - # extra_lit_opts: --param matrix-xmx8=True --param gpu-intel-dg2=True # env: '{"LIT_FILTER":${{ needs.determine_arc_tests.outputs.arc_tests }} }' # - name: E2E tests with dev igc on Intel Arc A-Series Graphics # runner: '["Linux", "arc"]' @@ -107,22 +222,20 @@ jobs: # ${{ contains(needs.detect_changes.outputs.filters, 'drivers') || # contains(needs.detect_changes.outputs.filters, 'devigccfg') }} # use_dev_igc: ${{ contains(needs.detect_changes.outputs.filters, 'devigccfg') }} - # extra_lit_opts: --param matrix-xmx8=True --param gpu-intel-dg2=True # env: '{"LIT_FILTER":${{ needs.determine_arc_tests.outputs.arc_tests }} }' # # Run only if the PR does not have the 'ci-no-devigc' label. # skip_run: ${{ contains(github.event.pull_request.labels.*.name, 'ci-no-devigc') }} - uses: ./.github/workflows/sycl-linux-run-tests.yml + uses: ./.github/workflows/sycl-linux-benchmark.yml with: name: ${{ matrix.name }} - runner: ${{ matrix. runner }} + runner: ${{ matrix.runner }} image: ${{ matrix.image }} image_options: ${{ matrix.image_options }} target_devices: ${{ matrix.target_devices }} reset_intel_gpu: ${{ matrix.reset_intel_gpu }} install_drivers: ${{ matrix.install_drivers }} use_dev_igc: ${{ matrix.use_dev_igc }} - extra_lit_opts: ${{ matrix.extra_lit_opts }} env: ${{ matrix.env || '{}' }} skip_run: ${{ matrix.skip_run || 'false' }} tests_selector: "benchmark" @@ -133,54 +246,3 @@ jobs: sycl_toolchain_artifact: sycl_linux_default sycl_toolchain_archive: ${{ needs.build.outputs.artifact_archive_name }} sycl_toolchain_decompress_command: ${{ needs.build.outputs.artifact_decompress_command }} - - - test-perf: - needs: [build, detect_changes] - if: | - always() && !cancelled() - && needs.build.outputs.build_conclusion == 'success' - && (contains(github.event.pull_request.labels.*.name, 'run-perf-tests') - || contains(needs.detect_changes.outputs.filters, 'perf-tests')) - strategy: - fail-fast: false - matrix: - include: - - name: Intel GEN12 Graphics system - runner: '["Linux", "gen12"]' - image: ghcr.io/intel/llvm/ubuntu2204_intel_drivers:latest - image_extra_opts: --device=/dev/dri - reset_intel_gpu: true - - name: Intel Arc A-Series Graphics system - runner: '["Linux", "arc"]' - image: ghcr.io/intel/llvm/ubuntu2204_intel_drivers:latest - image_extra_opts: --device=/dev/dri - reset_intel_gpu: true - - name: AMD system - runner: '["Linux", "amdgpu"]' - image: ghcr.io/intel/llvm/ubuntu2204_build:latest - image_extra_opts: --device=/dev/dri --device=/dev/kfd - extra_cmake_args: -DHIP_PLATFORM="AMD" -DAMD_ARCH="gfx1031" - - name: CUDA system - runner: '["Linux", "cuda"]' - image: ghcr.io/intel/llvm/ubuntu2204_build:latest - image_extra_opts: --gpus all - uses: ./.github/workflows/sycl-linux-run-tests.yml - with: - name: Perf tests on ${{ matrix.name }} - runner: ${{ matrix. runner }} - image: ${{ matrix.image }} - image_options: -u 1001 --privileged --cap-add SYS_ADMIN ${{ matrix.image_extra_opts }} - target_devices: all - reset_intel_gpu: ${{ matrix.reset_intel_gpu }} - - env: '{"LIT_FILTER":"PerformanceTests/"}' - extra_lit_opts: -a -j 1 --param enable-perf-tests=True - extra_cmake_args: ${{ matrix.extra_cmake_args }} - - ref: ${{ github.sha }} - merge_ref: '' - - sycl_toolchain_artifact: sycl_linux_default - sycl_toolchain_archive: ${{ needs.build.outputs.artifact_archive_name }} - sycl_toolchain_decompress_command: ${{ needs.build.outputs.artifact_decompress_command }} diff --git a/.github/workflows/sycl-linux-run-tests.yml b/.github/workflows/sycl-linux-run-tests.yml index 6097f90f5876..5efe42475746 100644 --- a/.github/workflows/sycl-linux-run-tests.yml +++ b/.github/workflows/sycl-linux-run-tests.yml @@ -28,7 +28,7 @@ on: required: False tests_selector: description: | - Three options: "e2e", "cts", "benchmark". + Two options: "e2e", "cts" type: string default: "e2e" @@ -117,7 +117,6 @@ on: options: - e2e - cts - - benchmark env: description: | @@ -379,39 +378,3 @@ jobs: grep 'exit code: [^0]' -r logs >> $GITHUB_STEP_SUMMARY exit $ret - - - name: Install deps - if: inputs.tests_selector == 'benchmark' && success() - run: | - sudo apt install -y ssh - - name: Run compute-benchmarks - id: run_benchmarks - if: inputs.tests_selector == 'benchmark' && success() - run: | - export CMPLR_ROOT=$PWD/toolchain - ./devops/scripts/benchmarking/benchmark.sh - echo $? - - name: Push compute-benchmarks - if: inputs.tests_selector == 'benchmark' && success() - env: - SSH_KEY: ${{secrets.ACTIONS_DEPLOY_KEY}} - run: | - find -maxdepth 3 - mkdir -p ~/.ssh - echo "$SSH_KEY" > ~/.ssh/id_rsa - chmod 600 ~/.ssh/id_rsa - eval "$(ssh-agent -s)" - ssh-add -k ~/.ssh/id_rsa - cd llvm-ci-perf-results - git config --global user.name "iclsrc" - git config --global user.email "ia.compiler.tools.git@intel.com" - git add . - git commit -m "Update results" - git push - # - name: Upload sycl-bench microbenchmark results - # if: inputs.tests_selector == 'benchmark' && steps.run_benchmarks.outcome == 'success' - # uses: actions/upload-artifact@v4 - # with: - # name: sycl_benchmark_res_${{ steps.run_benchmarks.outputs.TIMESTAMP }} - # path: ${{ steps.run_benchmarks.outputs.BENCHMARK_RESULTS }} - # retention-days: 7 \ No newline at end of file