Skip to content

Commit 16e525a

Browse files
Merge pull request #1082 from lukaszstolarczuk/bench-runner
New bench runner
2 parents 222dd3d + 3f76e93 commit 16e525a

File tree

4 files changed

+67
-41
lines changed

4 files changed

+67
-41
lines changed

.github/scripts/get_system_info.sh

Lines changed: 25 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#!/bin/bash
2-
# Copyright (C) 2024 Intel Corporation
2+
# Copyright (C) 2024-2025 Intel Corporation
33
# Under the Apache License v2.0 with LLVM Exceptions. See LICENSE.TXT.
44
# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
55

@@ -26,32 +26,32 @@ function system_info {
2626
cat /etc/os-release | grep -oP "PRETTY_NAME=\K.*"
2727
cat /proc/version
2828

29-
# echo "**********SYCL-LS**********"
30-
# source /opt/intel/oneapi/setvars.sh
31-
# sycl-ls
29+
echo "**********SYCL-LS**********"
30+
source /opt/intel/oneapi/setvars.sh
31+
sycl-ls
3232

3333
echo "**********numactl topology**********"
3434
numactl -H
3535

3636
echo "**********VGA info**********"
3737
lspci | grep -i VGA
3838

39-
# echo "**********CUDA Version**********"
40-
# if command -v nvidia-smi &> /dev/null; then
41-
# nvidia-smi
42-
# else
43-
# echo "CUDA not installed"
44-
# fi
39+
echo "**********CUDA Version**********"
40+
if command -v nvidia-smi &> /dev/null; then
41+
nvidia-smi
42+
else
43+
echo "CUDA not installed"
44+
fi
4545

4646
echo "**********L0 Version**********"
4747
check_L0_version
4848

49-
# echo "**********ROCm Version**********"
50-
# if command -v rocminfo &> /dev/null; then
51-
# rocminfo
52-
# else
53-
# echo "ROCm not installed"
54-
# fi
49+
echo "**********ROCm Version**********"
50+
if command -v rocminfo &> /dev/null; then
51+
rocminfo
52+
else
53+
echo "ROCm not installed"
54+
fi
5555

5656
echo "******OpenCL*******"
5757
# The driver version of OpenCL Graphics is the compute-runtime version
@@ -67,11 +67,15 @@ function system_info {
6767
cat /proc/meminfo
6868

6969
echo "**********env variables**********"
70-
echo "PATH=${PATH}"
71-
echo "CPATH=${CPATH}"
72-
echo "LD_LIBRARY_PATH=${LD_LIBRARY_PATH}"
73-
echo "LIBRARY_PATH=${LIBRARY_PATH}"
74-
echo "PKG_CONFIG_PATH=${PKG_CONFIG_PATH}"
70+
echo "PATH=$PATH"
71+
echo
72+
echo "CPATH=$CPATH"
73+
echo
74+
echo "LD_LIBRARY_PATH=$LD_LIBRARY_PATH"
75+
echo
76+
echo "LIBRARY_PATH=$LIBRARY_PATH"
77+
echo
78+
echo "PKG_CONFIG_PATH=$PKG_CONFIG_PATH"
7579
echo
7680

7781
echo "******build tools versions*******"

.github/workflows/docs.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ name: GitHubPages
44
on:
55
push:
66
branches: ["main"]
7+
workflow_dispatch:
78

89
# Cancel previous in-progress workflow, only the latest run is relevant
910
concurrency:

.github/workflows/nightly.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
# Various non-standard tests, requiring e.g. longer run
22
name: Nightly
33

4-
# This job is run at 00:00 UTC every day or on demand.
4+
# This job is run at 04:00 UTC every day or on demand.
55
on:
66
workflow_dispatch:
77
schedule:
8-
- cron: '0 0 * * *'
8+
- cron: '0 4 * * *'
99

1010
permissions:
1111
contents: read

.github/workflows/reusable_benchmarks.yml

Lines changed: 39 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Executes benchmarks implemented in this repository
2-
# using scripts for benchmark results visualisation,
2+
# using scripts for benchmark results visualization,
33
# which are downloaded from Unified Runtime repository.
44
name: Benchmarks
55

@@ -31,10 +31,9 @@ env:
3131
jobs:
3232
benchmarks:
3333
name: Benchmarks
34-
strategy:
35-
matrix:
36-
os: ['ubuntu-latest']
37-
runs-on: ${{matrix.os}}
34+
# run only on upstream; forks will not have the HW
35+
if: github.repository == 'oneapi-src/unified-memory-framework'
36+
runs-on: L0_PERF
3837

3938
steps:
4039
# Workspace on self-hosted runners is not cleaned automatically.
@@ -79,12 +78,7 @@ jobs:
7978
git checkout origin/pr/${PR_NO}/merge
8079
git rev-parse origin/pr/${PR_NO}/merge
8180
82-
- name: Install apt packages
83-
run: |
84-
sudo apt-get update
85-
sudo apt-get install -y cmake libhwloc-dev libnuma-dev libtbb-dev
86-
87-
- name: Configure build
81+
- name: Configure UMF
8882
run: >
8983
cmake
9084
-S ${{env.UMF_DIR}}
@@ -94,19 +88,19 @@ jobs:
9488
-DUMF_BUILD_BENCHMARKS=ON
9589
-DUMF_BUILD_BENCHMARKS_MT=ON
9690
-DUMF_BUILD_TESTS=OFF
97-
-DUMF_FORMAT_CODE_STYLE=OFF
91+
-DUMF_BUILD_EXAMPLES=OFF
9892
-DUMF_DEVELOPER_MODE=OFF
93+
-DUMF_FORMAT_CODE_STYLE=OFF
9994
-DUMF_BUILD_LEVEL_ZERO_PROVIDER=ON
10095
-DUMF_BUILD_CUDA_PROVIDER=ON
10196
-DUMF_BUILD_LIBUMF_POOL_DISJOINT=ON
10297
-DUMF_BUILD_LIBUMF_POOL_JEMALLOC=ON
103-
-DUMF_BUILD_EXAMPLES=OFF
10498
10599
- name: Build UMF
106100
run: cmake --build ${{env.BUILD_DIR}} -j $(nproc)
107101

108102
# We are going to clone Unified Runtime repository in order to run
109-
# the most up-to-date UR scripts for benchmark data visualisation
103+
# the most up-to-date UR scripts for benchmark data visualization
110104
- name: Checkout UR
111105
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
112106
with:
@@ -119,16 +113,38 @@ jobs:
119113
run: |
120114
pip install --force-reinstall -r ${{github.workspace}}/ur-repo/third_party/benchmark_requirements.txt
121115
122-
- name: Run dedicated for UMF benchmarking scripts from UR
116+
- name: Set core range and GPU mask
117+
run: |
118+
# Compute the core range for the second NUMA node; first node is for UR jobs.
119+
# Skip the first 4 cores - the kernel is likely to schedule more work on these.
120+
CORES=$(lscpu | awk '
121+
/NUMA node1 CPU|On-line CPU/ {line=$0}
122+
END {
123+
split(line, a, " ")
124+
split(a[4], b, ",")
125+
sub(/^0/, "4", b[1])
126+
print b[1]
127+
}')
128+
echo "Selected core: $CORES"
129+
echo "CORES=$CORES" >> $GITHUB_ENV
130+
131+
ZE_AFFINITY_MASK=1
132+
echo "ZE_AFFINITY_MASK=$ZE_AFFINITY_MASK" >> $GITHUB_ENV
133+
134+
- name: Run UMF benchmarks (using scripts from UR)
123135
id: benchmarks
124136
working-directory: ${{env.BUILD_DIR}}
125137
run: >
126-
${{ github.workspace }}/ur-repo/scripts/benchmarks/main.py
127-
~/bench_workdir
128-
--umf ${{env.BUILD_DIR}}
138+
taskset -c ${{ env.CORES }} ${{ github.workspace }}/ur-repo/scripts/benchmarks/main.py
139+
~/bench_workdir_umf
140+
--umf ${{env.BUILD_DIR}}
129141
${{ inputs.upload_report && '--output-html' || '' }}
130142
${{ inputs.bench_script_params }}
131143
144+
- name: Print benchmark results
145+
if: ${{ always() }}
146+
run: cat ${{env.BUILD_DIR}}/benchmark_results.md
147+
132148
- name: Add comment to PR
133149
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1
134150
if: ${{ always() && inputs.pr_no != 0 }}
@@ -161,3 +177,8 @@ jobs:
161177
with:
162178
path: umf-repo/build/benchmark_results.html
163179
key: benchmark-results-${{ github.run_id }}
180+
181+
- name: Get information about platform
182+
if: ${{ always() }}
183+
working-directory: ${{env.UMF_DIR}}
184+
run: .github/scripts/get_system_info.sh

0 commit comments

Comments
 (0)