Skip to content

Commit 7c176da

Browse files
nirvdrumtekknolagi
authored andcommitted
ZJIT: Run CI jobs with both the inliner enabled an disabled
1 parent 594d14d commit 7c176da

2 files changed

Lines changed: 34 additions & 13 deletions

File tree

.github/workflows/zjit-macos.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -181,11 +181,18 @@ jobs:
181181
strategy:
182182
matrix:
183183
include:
184+
# Run with the inliner enabled (on by default)
184185
# Test --call-threshold=2 with 2 iterations in total
185186
- ruby_opts: '--zjit-call-threshold=2'
186187
bench_opts: '--warmup=1 --bench=1 --excludes=shipit'
187188
configure: '--enable-zjit=dev_nodebug' # --enable-zjit=dev is too slow
188189

190+
# Run with inliner disabled #
191+
# Test --call-threshold=2 with 2 iterations in total
192+
- ruby_opts: '--zjit-inline-threshold=0 --zjit-call-threshold=2'
193+
bench_opts: '--warmup=1 --bench=1 --excludes=shipit'
194+
configure: '--enable-zjit=dev_nodebug' # --enable-zjit=dev is too slow
195+
189196
runs-on: macos-26
190197

191198
if: >-

.github/workflows/zjit-ubuntu.yml

Lines changed: 27 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -58,28 +58,43 @@ jobs:
5858
fail-fast: false
5959
matrix:
6060
include:
61+
- test_task: 'check'
62+
run_opts: '--zjit-disable-hir-opt --zjit-call-threshold=1'
63+
specopts: '-T --zjit-disable-hir-opt -T --zjit-call-threshold=1'
64+
configure: '--enable-zjit=dev'
65+
66+
## Run with default options (inliner enabled) ##
6167
- test_task: 'check'
6268
run_opts: '--zjit-call-threshold=1'
6369
specopts: '-T --zjit-call-threshold=1'
6470
configure: '--enable-zjit=dev'
6571

66-
- test_task: 'check'
67-
run_opts: '--zjit-call-threshold=1 --zjit-inline-threshold=30'
68-
specopts: '-T --zjit-call-threshold=1 -T --zjit-inline-threshold=30'
72+
# The optimizer benefits from at least 1 iteration of profiling. Also, many
73+
# regression tests in bootstraptest/test_yjit.rb assume call-threshold=2.
74+
- test_task: 'btest'
75+
run_opts: '--zjit-call-threshold=2'
6976
configure: '--enable-zjit=dev'
70-
continue-on-test_task: true
7177

78+
- test_task: 'test-bundled-gems'
79+
configure: '--enable-zjit=dev'
80+
run_opts: '--zjit-call-threshold=1'
81+
82+
## Run with inliner disabled ##
7283
- test_task: 'check'
73-
run_opts: '--zjit-disable-hir-opt --zjit-call-threshold=1'
74-
specopts: '-T --zjit-disable-hir-opt -T --zjit-call-threshold=1'
84+
run_opts: '--zjit-inline-threshold=0 --zjit-call-threshold=1'
85+
specopts: '-T --zjit-inline-threshold=0 -T --zjit-call-threshold=1'
7586
configure: '--enable-zjit=dev'
7687

7788
# The optimizer benefits from at least 1 iteration of profiling. Also, many
7889
# regression tests in bootstraptest/test_yjit.rb assume call-threshold=2.
7990
- test_task: 'btest'
80-
run_opts: '--zjit-call-threshold=2'
91+
run_opts: '--zjit-inline-threshold=0 --zjit-call-threshold=2'
8192
configure: '--enable-zjit=dev'
8293

94+
- test_task: 'test-bundled-gems'
95+
configure: '--enable-zjit=dev'
96+
run_opts: '--zjit-inline-threshold=0 --zjit-call-threshold=1'
97+
8398
- test_task: 'zjit-check' # zjit-test + quick feedback of test_zjit.rb
8499
configure: '--enable-yjit --enable-zjit=dev'
85100
rust_version: '1.85.0'
@@ -91,10 +106,6 @@ jobs:
91106
clang_path: '/usr/bin/clang-16'
92107
runs-on: 'ubuntu-24.04' # for clang-16
93108

94-
- test_task: 'test-bundled-gems'
95-
configure: '--enable-zjit=dev'
96-
run_opts: '--zjit-call-threshold=1'
97-
98109
env:
99110
GITPULLOPTIONS: --no-tags origin ${{ github.ref }}
100111
RUN_OPTS: ${{ matrix.run_opts }}
@@ -246,11 +257,14 @@ jobs:
246257
strategy:
247258
matrix:
248259
include:
249-
# Test --call-threshold=2 with 2 iterations in total
260+
# Test --call-threshold=2 with 2 iterations in total (inlining enabled)
250261
- ruby_opts: '--zjit-call-threshold=2'
251262
bench_opts: '--warmup=1 --bench=1 --excludes=shipit'
252263
configure: '--enable-zjit=dev_nodebug' # --enable-zjit=dev is too slow
253-
264+
# Test --call-threshold=2 with 2 iterations in total (inlining disabled)
265+
- ruby_opts: '--zjit-inline-threshold=0 --zjit-call-threshold=2'
266+
bench_opts: '--warmup=1 --bench=1 --excludes=shipit'
267+
configure: '--enable-zjit=dev_nodebug' # --enable-zjit=dev is too slow
254268
runs-on: ubuntu-24.04
255269

256270
if: >-

0 commit comments

Comments
 (0)