forked from solvcon/modmesh
-
Notifications
You must be signed in to change notification settings - Fork 0
90 lines (73 loc) · 2.63 KB
/
profiling.yml
File metadata and controls
90 lines (73 loc) · 2.63 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
name: profiling
on:
push:
pull_request:
schedule:
- cron: '34 17 * * *'
jobs:
profile:
# Run profiling only on schedule or when MMGH_FORCE_PROFILE is set to 'enable'
# You can refer to https://docs.github.com/en/actions/how-tos/write-workflows/choose-what-workflows-do/use-variables to set MMGH_FORCE_PROFILE in the fork repository settings for testing purposes.
if: ${{ (github.event_name == 'schedule' && vars.MMGH_NIGHTLY == 'enable') || vars.MMGH_FORCE_PROFILE == 'enable' }}
name: profile_${{ matrix.os }}
runs-on: ${{ matrix.os }}
timeout-minutes: ${{ fromJSON(vars.MMGH_TIMEOUT_PROFILE || '30') }}
env:
QT_DEBUG_PLUGINS: 1
QT_QPA_PLATFORM: offscreen # for Ubuntu runner
PIP_BREAK_SYSTEM_PACKAGES: 1 # disabling PEP668 (for MacOS runner)
# Fix issue: https://github.com/solvcon/modmesh/issues/366
# Use custom config for jurplel/install-qt-action@v4
AQT_CONFIG: "thirdparty/aqt_settings.ini"
strategy:
matrix:
os: [ubuntu-24.04, macos-26]
fail-fast: false
steps:
- uses: actions/checkout@v6
with:
fetch-depth: 1
- name: event name
run: |
echo "Event name: ${{ github.event_name }}"
- name: setup dependencies for Linux
if: runner.os == 'Linux'
uses: ./.github/actions/setup_linux
with:
workflow: 'build'
- name: setup dependencies for macOS
if: runner.os == 'macOS'
uses: ./.github/actions/setup_macos
with:
workflow: 'build'
- name: ccache
uses: hendrikmuhs/ccache-action@v1.2.23
with:
key: ${{ runner.os }}-Release
restore-keys: ${{ runner.os }}-Release
create-symlink: true
save: false
- name: make buildext BUILD_QT=ON
run: |
echo "::group::make buildext BUILD_QT=ON"
make cmake \
VERBOSE=1 USE_CLANG_TIDY=OFF \
BUILD_QT=ON \
CMAKE_ARGS="-DPYTHON_EXECUTABLE=$(which python3)"
make buildext VERBOSE=1
echo "::endgroup::"
- name: make pyprof
run: |
echo "::group::make pyprof"
make pyprof
echo "::endgroup::"
send_email_on_failure:
needs: [profile]
if: ${{ always() && contains(needs.*.result, 'failure') && github.ref_name == 'master' && github.event.repository.fork == false }}
uses: ./.github/workflows/send_email_on_fail.yml
with:
job_results: |
- profile: ${{ needs.profile.result }}
secrets:
EMAIL_USERNAME: ${{ secrets.EMAIL_USERNAME }}
EMAIL_PASSWORD: ${{ secrets.EMAIL_PASSWORD }}