Skip to content

Commit b5152e7

Browse files
committed
add regular tests under fuzz in nighlty CI
1 parent 58ceb32 commit b5152e7

File tree

1 file changed

+9
-305
lines changed

1 file changed

+9
-305
lines changed

.github/workflows/nightly.yml

+9-305
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,12 @@
22
name: Nightly
33

44
# This job is run at 04:00 UTC every day or on demand.
5+
56
on:
6-
workflow_dispatch:
7-
schedule:
8-
- cron: '0 4 * * *'
7+
push:
8+
branches-ignore:
9+
- 'dependabot/**'
10+
pull_request:
911

1012
permissions:
1113
contents: read
@@ -50,308 +52,10 @@ jobs:
5052
- name: Build
5153
run: cmake --build ${{github.workspace}}/build --config ${{matrix.build_type}} --verbose -j$(nproc)
5254

55+
- name: Run regular tests
56+
working-directory: ${{github.workspace}}/build
57+
run: ctest -C ${{matrix.build_type}} --output-on-failure --verbose -E "fuzz"
58+
5359
- name: Fuzz long test
5460
working-directory: ${{github.workspace}}/build
5561
run: ctest -C ${{matrix.build_type}} --output-on-failure --verbose -L "fuzz-long"
56-
57-
valgrind:
58-
name: Valgrind
59-
strategy:
60-
fail-fast: false
61-
matrix:
62-
tool: ['memcheck', 'drd', 'helgrind']
63-
runs-on: ubuntu-latest
64-
65-
steps:
66-
- name: Checkout repository
67-
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
68-
with:
69-
fetch-depth: 0
70-
71-
- name: Install apt packages
72-
run: |
73-
sudo apt-get update
74-
sudo apt-get install -y cmake hwloc libhwloc-dev libnuma-dev libtbb-dev valgrind
75-
76-
- name: Configure CMake
77-
run: >
78-
cmake
79-
-B ${{github.workspace}}/build
80-
-DCMAKE_BUILD_TYPE=Debug
81-
-DUMF_FORMAT_CODE_STYLE=OFF
82-
-DUMF_DEVELOPER_MODE=ON
83-
-DUMF_BUILD_LIBUMF_POOL_JEMALLOC=ON
84-
-DUMF_BUILD_LEVEL_ZERO_PROVIDER=OFF
85-
-DUMF_BUILD_CUDA_PROVIDER=OFF
86-
-DUMF_USE_VALGRIND=1
87-
-DUMF_TESTS_FAIL_ON_SKIP=ON
88-
89-
- name: Build
90-
run: cmake --build ${{github.workspace}}/build --config Debug -j$(nproc)
91-
92-
- name: Run tests under valgrind
93-
run: ${{github.workspace}}/test/test_valgrind.sh ${{github.workspace}} ${{github.workspace}}/build ${{matrix.tool}}
94-
95-
Windows-generators:
96-
name: Windows ${{matrix.generator}} generator
97-
strategy:
98-
matrix:
99-
build_type: [Debug, Release]
100-
compiler: [{c: cl, cxx: cl}]
101-
shared_library: ['ON', 'OFF']
102-
static_hwloc: ['ON', 'OFF']
103-
generator: ['Ninja', 'NMake Makefiles']
104-
umfd_lib: ['ON', 'OFF']
105-
106-
runs-on: windows-latest
107-
108-
steps:
109-
- name: Checkout
110-
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
111-
with:
112-
fetch-depth: 0
113-
114-
- name: Set VCPKG_PATH with hwloc
115-
if: matrix.static_hwloc == 'OFF'
116-
run: echo "VCPKG_PATH=${{github.workspace}}/build/vcpkg/packages/hwloc_x64-windows;${{github.workspace}}/build/vcpkg/packages/tbb_x64-windows;${{github.workspace}}/build/vcpkg/packages/jemalloc_x64-windows" >> $env:GITHUB_ENV
117-
118-
- name: Set VCPKG_PATH without hwloc
119-
if: matrix.static_hwloc == 'ON'
120-
run: echo "VCPKG_PATH=${{github.workspace}}/build/vcpkg/packages/tbb_x64-windows;${{github.workspace}}/build/vcpkg/packages/jemalloc_x64-windows" >> $env:GITHUB_ENV
121-
122-
- name: Initialize vcpkg
123-
uses: lukka/run-vcpkg@5e0cab206a5ea620130caf672fce3e4a6b5666a1 # v11.5
124-
env:
125-
VCPKG_PATH: ${{env.VCPKG_PATH}}
126-
with:
127-
vcpkgGitCommitId: ea2a964f9303270322cf3f2d51c265ba146c422d # 1.04.2025
128-
vcpkgDirectory: ${{env.BUILD_DIR}}/vcpkg
129-
vcpkgJsonGlob: '**/vcpkg.json'
130-
131-
- name: Install dependencies
132-
run: vcpkg install --triplet x64-windows
133-
134-
- name: Install Ninja
135-
if: matrix.generator == 'Ninja'
136-
uses: seanmiddleditch/gha-setup-ninja@3b1f8f94a2f8254bd26914c4ab9474d4f0015f67 # v6
137-
138-
- name: Configure MSVC environment
139-
uses: ilammy/msvc-dev-cmd@0b201ec74fa43914dc39ae48a89fd1d8cb592756 # v1.13.0
140-
141-
- name: Configure build
142-
run: >
143-
cmake
144-
-B ${{env.BUILD_DIR}}
145-
-DCMAKE_BUILD_TYPE=${{matrix.build_type}}
146-
-DCMAKE_PREFIX_PATH="${{env.VCPKG_PATH}}"
147-
-DCMAKE_C_COMPILER=${{matrix.compiler.c}}
148-
-DCMAKE_CXX_COMPILER=${{matrix.compiler.cxx}}
149-
-G "${{matrix.generator}}"
150-
-DUMF_BUILD_SHARED_LIBRARY=${{matrix.shared_library}}
151-
-DUMF_LINK_HWLOC_STATICALLY=${{matrix.static_hwloc}}
152-
-DUMF_FORMAT_CODE_STYLE=OFF
153-
-DUMF_DEVELOPER_MODE=ON
154-
-DUMF_BUILD_LIBUMF_POOL_JEMALLOC=ON
155-
-DUMF_BUILD_LEVEL_ZERO_PROVIDER=ON
156-
-DUMF_BUILD_CUDA_PROVIDER=ON
157-
-DUMF_TESTS_FAIL_ON_SKIP=ON
158-
${{ matrix.umfd_lib == 'ON' && '-DUMF_USE_DEBUG_POSTFIX=ON' || '' }}
159-
160-
- name: Build UMF
161-
shell: cmd
162-
run: cmake --build ${{env.BUILD_DIR}} --config ${{matrix.build_type}} -j %NUMBER_OF_PROCESSORS%
163-
164-
- name: Run tests
165-
shell: cmd
166-
working-directory: ${{env.BUILD_DIR}}
167-
run: ctest -C ${{matrix.build_type}} --output-on-failure --test-dir test
168-
169-
- name: Get UMF version
170-
run: |
171-
$version = (git describe --tags --abbrev=0 | Select-String -Pattern '\d+\.\d+\.\d+').Matches.Value
172-
echo "UMF_VERSION=$version" >> $env:GITHUB_ENV
173-
shell: pwsh
174-
175-
- name: Test UMF installation and uninstallation
176-
# The '--shared-library' parameter is added to the installation test when the UMF is built as a shared library
177-
# The '--umfd-lib' parameter is added when the UMF is built with the umfd library
178-
run: >
179-
python3 ${{github.workspace}}/test/test_installation.py
180-
--build-dir ${{env.BUILD_DIR}}
181-
--install-dir ${{env.INSTALL_DIR}}
182-
--build-type ${{matrix.build_type}}
183-
--umf-version ${{env.UMF_VERSION}}
184-
${{ matrix.shared_library == 'ON' && '--proxy --shared-library' || '' }}
185-
${{ matrix.umfd_lib == 'ON' && '--umfd-lib' || ''}}
186-
${{ matrix.static_hwloc == 'ON' && '--hwloc' || '' }}
187-
188-
icx:
189-
name: ICX
190-
env:
191-
VCPKG_PATH: "${{github.workspace}}/build/vcpkg/packages/hwloc_x64-windows;${{github.workspace}}/build/vcpkg/packages/tbb_x64-windows;${{github.workspace}}/build/vcpkg/packages/jemalloc_x64-windows"
192-
strategy:
193-
matrix:
194-
os: ['windows-2019', 'windows-2022']
195-
build_type: [Debug]
196-
compiler: [{c: icx, cxx: icx}]
197-
shared_library: ['ON', 'OFF']
198-
include:
199-
- os: windows-2022
200-
build_type: Release
201-
compiler: {c: icx, cxx: icx}
202-
shared_library: 'ON'
203-
204-
runs-on: ${{matrix.os}}
205-
206-
steps:
207-
- name: Checkout
208-
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
209-
with:
210-
fetch-depth: 0
211-
212-
- name: Initialize vcpkg
213-
uses: lukka/run-vcpkg@5e0cab206a5ea620130caf672fce3e4a6b5666a1 # v11.5
214-
with:
215-
vcpkgGitCommitId: ea2a964f9303270322cf3f2d51c265ba146c422d # 1.04.2025
216-
vcpkgDirectory: ${{env.BUILD_DIR}}/vcpkg
217-
vcpkgJsonGlob: '**/vcpkg.json'
218-
219-
- name: Install dependencies
220-
run: vcpkg install --triplet x64-windows
221-
222-
- name: Install Ninja
223-
uses: seanmiddleditch/gha-setup-ninja@3b1f8f94a2f8254bd26914c4ab9474d4f0015f67 # v6
224-
225-
- name: Download icx compiler
226-
env:
227-
# Link source: https://www.intel.com/content/www/us/en/developer/tools/oneapi/dpc-compiler-download.html
228-
CMPLR_LINK: "https://registrationcenter-download.intel.com/akdlm/IRC_NAS/15a35578-2f9a-4f39-804b-3906e0a5f8fc/w_dpcpp-cpp-compiler_p_2024.2.1.83_offline.exe"
229-
run: |
230-
Invoke-WebRequest -Uri "${{ env.CMPLR_LINK }}" -OutFile compiler_install.exe
231-
232-
- name: Install icx compiler
233-
shell: cmd
234-
run: |
235-
start /b /wait .\compiler_install.exe -s -x -f extracted --log extract.log
236-
extracted\bootstrapper.exe -s --action install --eula=accept -p=NEED_VS2017_INTEGRATION=0 ^
237-
-p=NEED_VS2019_INTEGRATION=0 -p=NEED_VS2022_INTEGRATION=0 --log-dir=.
238-
239-
- name: Configure build
240-
shell: cmd
241-
run: |
242-
call "C:\Program Files (x86)\Intel\oneAPI\setvars.bat"
243-
call "C:\Program Files (x86)\Intel\oneAPI\setvars-vcvarsall.bat"
244-
cmake ^
245-
-B ${{env.BUILD_DIR}} ^
246-
-DCMAKE_PREFIX_PATH="${{env.VCPKG_PATH}}" ^
247-
-DCMAKE_C_COMPILER=${{matrix.compiler.c}} ^
248-
-DCMAKE_CXX_COMPILER=${{matrix.compiler.cxx}} ^
249-
-G Ninja ^
250-
-DUMF_BUILD_SHARED_LIBRARY=${{matrix.shared_library}} ^
251-
-DUMF_FORMAT_CODE_STYLE=OFF ^
252-
-DUMF_DEVELOPER_MODE=ON ^
253-
-DUMF_BUILD_LIBUMF_POOL_JEMALLOC=ON ^
254-
-DUMF_BUILD_LEVEL_ZERO_PROVIDER=ON ^
255-
-DUMF_BUILD_CUDA_PROVIDER=ON ^
256-
-DUMF_TESTS_FAIL_ON_SKIP=ON
257-
258-
- name: Build UMF
259-
shell: cmd
260-
run: |
261-
call "C:\Program Files (x86)\Intel\oneAPI\setvars.bat"
262-
call "C:\Program Files (x86)\Intel\oneAPI\setvars-vcvarsall.bat"
263-
cmake --build ${{env.BUILD_DIR}} --config ${{matrix.build_type}} -j %NUMBER_OF_PROCESSORS%
264-
265-
- name: Run tests
266-
shell: cmd
267-
working-directory: ${{env.BUILD_DIR}}
268-
run: |
269-
call "C:\Program Files (x86)\Intel\oneAPI\setvars.bat"
270-
call "C:\Program Files (x86)\Intel\oneAPI\setvars-vcvarsall.bat"
271-
ctest -C ${{matrix.build_type}} --output-on-failure --test-dir test
272-
273-
# Scenarios where UMF_LINK_HWLOC_STATICALLY is set to OFF and hwloc is not installed in the system
274-
# The hwloc library is fetched implicitly
275-
hwloc-fallback:
276-
name: "Fallback to static hwloc build"
277-
strategy:
278-
matrix:
279-
include:
280-
- os: 'ubuntu-latest'
281-
build_type: Release
282-
number_of_processors: '$(nproc)'
283-
- os: 'windows-latest'
284-
build_type: Release
285-
number_of_processors: '$Env:NUMBER_OF_PROCESSORS'
286-
287-
runs-on: ${{matrix.os}}
288-
289-
steps:
290-
- name: Install dependencies
291-
if: matrix.os == 'ubuntu-latest'
292-
run: sudo apt-get install -y libnuma-dev
293-
294-
- name: Checkout
295-
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
296-
with:
297-
fetch-depth: 0
298-
299-
- name: Configure build
300-
run: >
301-
cmake
302-
-B ${{env.BUILD_DIR}}
303-
-DCMAKE_BUILD_TYPE=${{matrix.build_type}}
304-
-DUMF_BUILD_SHARED_LIBRARY=ON
305-
-DUMF_BUILD_EXAMPLES=OFF
306-
-DUMF_DEVELOPER_MODE=ON
307-
-DUMF_LINK_HWLOC_STATICALLY=OFF
308-
-DUMF_TESTS_FAIL_ON_SKIP=ON
309-
310-
- name: Build UMF
311-
run: >
312-
cmake
313-
--build ${{env.BUILD_DIR}}
314-
--config ${{matrix.build_type}}
315-
-j ${{matrix.number_of_processors}}
316-
317-
- name: Run tests
318-
working-directory: ${{env.BUILD_DIR}}
319-
run: ctest -C ${{matrix.build_type}} --output-on-failure --test-dir test
320-
321-
L0:
322-
uses: ./.github/workflows/reusable_gpu.yml
323-
with:
324-
provider: "LEVEL_ZERO"
325-
runner: "L0"
326-
L0-BMG:
327-
uses: ./.github/workflows/reusable_gpu.yml
328-
with:
329-
provider: "LEVEL_ZERO"
330-
runner: "L0-BMG"
331-
os: "['Ubuntu']"
332-
CUDA:
333-
uses: ./.github/workflows/reusable_gpu.yml
334-
with:
335-
provider: "CUDA"
336-
runner: "CUDA"
337-
338-
# Full execution of QEMU tests
339-
QEMU:
340-
uses: ./.github/workflows/reusable_qemu.yml
341-
with:
342-
short_run: false
343-
# Beside the 2 LTS Ubuntu, we also test this on the latest Ubuntu - to be updated
344-
# every 6 months, so we verify the latest version of packages (compilers, etc.).
345-
os: "['ubuntu-22.04', 'ubuntu-24.04', 'ubuntu-24.10']"
346-
347-
Benchmarks:
348-
uses: ./.github/workflows/reusable_benchmarks.yml
349-
permissions:
350-
contents: write
351-
pull-requests: write
352-
with:
353-
pr_no: '0'
354-
bench_script_params: '--save Baseline_PVC'
355-
356-
SYCL:
357-
uses: ./.github/workflows/reusable_sycl.yml

0 commit comments

Comments
 (0)