From 31f6b845849ffa9158d22e92b380ed8f89d63812 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=81ukasz=20Stolarczuk?= Date: Wed, 19 Feb 2025 11:12:03 +0100 Subject: [PATCH 1/2] [CI] Update benchmark's scripts repo from UR to SYCL --- .github/workflows/reusable_benchmarks.yml | 27 +++++++++++------------ 1 file changed, 13 insertions(+), 14 deletions(-) diff --git a/.github/workflows/reusable_benchmarks.yml b/.github/workflows/reusable_benchmarks.yml index b41c99f3ab..a0dc7a1aa7 100644 --- a/.github/workflows/reusable_benchmarks.yml +++ b/.github/workflows/reusable_benchmarks.yml @@ -1,6 +1,5 @@ -# Executes benchmarks implemented in this repository -# using scripts for benchmark results visualization, -# which are downloaded from Unified Runtime repository. +# Executes benchmarks implemented in this repository using scripts +# for results visualization from intel/llvm (unified-runtime dir). name: Benchmarks on: @@ -98,23 +97,23 @@ jobs: - name: Build UMF run: cmake --build ${{env.BUILD_DIR}} -j $(nproc) - # We are going to clone Unified Runtime repository in order to run - # the most up-to-date UR scripts for benchmark data visualization - - name: Checkout UR + # Get scripts for benchmark data visualization. + # Use specific tag, as the scripts or files' location may change. + - name: Checkout SYCL uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 with: - repository: oneapi-src/unified-runtime - path: ur-repo + repository: intel/llvm + ref: nightly-2025-02-19 + path: sycl-repo fetch-depth: 1 - fetch-tags: false - - name: Install pip packages for benchmarking scripts from UR + - name: Install benchmarking scripts deps run: | - pip install --force-reinstall -r ${{github.workspace}}/ur-repo/third_party/benchmark_requirements.txt + pip install --force-reinstall -r ${{github.workspace}}/sycl-repo/unified-runtime/third_party/benchmark_requirements.txt - name: Set core range and GPU mask run: | - # Compute the core range for the second NUMA node; first node is for UR jobs. + # Compute the core range for the second NUMA node; first node is for SYCL/UR jobs. # Skip the first 4 cores - the kernel is likely to schedule more work on these. CORES=$(lscpu | awk ' /NUMA node1 CPU|On-line CPU/ {line=$0} @@ -130,11 +129,11 @@ jobs: ZE_AFFINITY_MASK=1 echo "ZE_AFFINITY_MASK=$ZE_AFFINITY_MASK" >> $GITHUB_ENV - - name: Run UMF benchmarks (using scripts from UR) + - name: Run UMF benchmarks id: benchmarks working-directory: ${{env.BUILD_DIR}} run: > - taskset -c ${{ env.CORES }} ${{ github.workspace }}/ur-repo/scripts/benchmarks/main.py + taskset -c ${{ env.CORES }} ${{ github.workspace }}/sycl-repo/unified-runtime/scripts/benchmarks/main.py ~/bench_workdir_umf --umf ${{env.BUILD_DIR}} ${{ inputs.upload_report && '--output-html' || '' }} From 4e7f117a23959f9105524f6de9cb9d19e03f6df7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=81ukasz=20Stolarczuk?= Date: Wed, 19 Feb 2025 11:14:22 +0100 Subject: [PATCH 2/2] [CI] Adjust benchmark scripts params to new scripts' version --- .github/workflows/reusable_benchmarks.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/reusable_benchmarks.yml b/.github/workflows/reusable_benchmarks.yml index a0dc7a1aa7..a7c9e5e285 100644 --- a/.github/workflows/reusable_benchmarks.yml +++ b/.github/workflows/reusable_benchmarks.yml @@ -136,11 +136,14 @@ jobs: taskset -c ${{ env.CORES }} ${{ github.workspace }}/sycl-repo/unified-runtime/scripts/benchmarks/main.py ~/bench_workdir_umf --umf ${{env.BUILD_DIR}} + --compare baseline ${{ inputs.upload_report && '--output-html' || '' }} + ${{ inputs.pr_no != 0 && '--output-markdown' || '' }} ${{ inputs.bench_script_params }} + # In case it failed to add a comment, we can still print the results. - name: Print benchmark results - if: ${{ always() }} + if: ${{ always() && inputs.pr_no != 0 }} run: cat ${{env.BUILD_DIR}}/benchmark_results.md - name: Add comment to PR