@@ -6,9 +6,8 @@ permissions:
6
6
id-token : write
7
7
8
8
on :
9
- # re-enable this when fixing the workflow
10
- # push:
11
- # branches: ["main"]
9
+ push :
10
+ branches : ["main"]
12
11
workflow_dispatch :
13
12
14
13
env :
@@ -183,13 +182,6 @@ jobs:
183
182
${{ env.HOME }}/.cargo/bin/inferno-*
184
183
key : ${{ runner.os }}-extra-binaries
185
184
186
- - name : Cache ethrex_l2
187
- id : cache-ethrex-l2
188
- uses : actions/cache@v4
189
- with :
190
- path : ${{ env.HOME }}/.cargo/bin/ethrex_l2
191
- key : ${{ runner.os }}-ethrex-l2-${{ hashFiles('cmd/ethrex_l2/Cargo.lock') }}
192
-
193
185
- name : Change perf settings
194
186
run : |
195
187
sudo sysctl kernel.perf_event_paranoid=-1
@@ -236,30 +228,18 @@ jobs:
236
228
echo "$HOME/.cargo/bin/inferno-collapse-perf" already found
237
229
fi
238
230
239
- - name : Install ethrex_l2 cli
240
- run : |
241
- if [ -f "$HOME/.cargo/bin/ethrex_l2" ]; then
242
- echo "$HOME/.cargo/bin/ethrex_l2" already found
243
- else
244
- cargo install --force --path cmd/ethrex_l2
245
- fi
246
- ethrex_l2 config create default --default
247
- ethrex_l2 config set default
248
-
249
231
# By default ethrex uses revm as evm backend.
250
232
- id : generate-flamegraph-ethrex
251
233
name : Generate Flamegraph data for Ethrex
252
234
shell : bash
253
235
run : |
254
236
rm -rf target/release/ethrex
237
+ cargo build --release --bin ethrex --features dev
255
238
CARGO_PROFILE_RELEASE_DEBUG=true cargo flamegraph -c "record -o perf.data -F997 --call-graph dwarf,16384 -g" \
256
- --bin ethrex --features dev -- --dev --network /home/runner/work/ethrex/ethrex/test_data/genesis-l2.json --http.port 1729 >/dev/null &
257
- while [ ! -x "./target/release/ethrex" ]; do
258
- echo "Waiting for ethrex binary to be ready..."
259
- sleep 2
260
- done
239
+ --bin ethrex --release --features dev -- \
240
+ --dev --network /home/runner/work/ethrex/ethrex/test_data/genesis-l2-ci.json --http.port 1729 >/dev/null &
261
241
sleep 10
262
- echo "Compilation finished. Executing load test..."
242
+ echo "Executing load test..."
263
243
bash /home/runner/work/ethrex/ethrex/.github/scripts/flamegraph_watcher.sh &&
264
244
echo "Load test finished"
265
245
@@ -293,12 +273,13 @@ jobs:
293
273
with :
294
274
toolchain : ${{ env.RUST_RETH_VERSION }}
295
275
276
+ # We need a reth version that requires a rustc version <= 1.82.0
296
277
- name : Checkout reth
297
278
uses : actions/checkout@v4
298
279
with :
299
280
repository : paradigmxyz/reth
300
281
path : " reth"
301
- ref : main
282
+ ref : b2ead06d1d0804101de0d1eb3a070e08d8eab857
302
283
303
284
- name : Caching
304
285
uses : Swatinem/rust-cache@v2
@@ -316,13 +297,6 @@ jobs:
316
297
${{ env.HOME }}/.cargo/bin/inferno-*
317
298
key : ${{ runner.os }}-extra-binaries
318
299
319
- - name : Cache ethrex_l2
320
- id : cache-ethrex-l2
321
- uses : actions/cache@v4
322
- with :
323
- path : ${{ env.HOME }}/.cargo/bin/ethrex_l2
324
- key : ${{ runner.os }}-ethrex-l2-${{ hashFiles('cmd/ethrex_l2/Cargo.lock') }}
325
-
326
300
- name : Change perf settings
327
301
run : |
328
302
sudo sysctl kernel.perf_event_paranoid=-1
@@ -369,35 +343,22 @@ jobs:
369
343
echo "$HOME/.cargo/bin/inferno-collapse-perf" already found
370
344
fi
371
345
372
- - name : Install ethrex_l2 cli
373
- run : |
374
- if [ -f "$HOME/.cargo/bin/ethrex_l2" ]; then
375
- echo "$HOME/.cargo/bin/ethrex_l2" already found
376
- else
377
- cargo install --force --path cmd/ethrex_l2
378
- fi
379
- ethrex_l2 config create default --default
380
- ethrex_l2 config set default
381
-
382
346
- id : generate-flamegraph-reth
383
347
name : Build and test reth
384
348
shell : bash
385
349
# --dev.block-time 1000ms set to 1000ms to match ethrex block generation time
386
350
run : |
387
351
cd ./reth
388
352
rm -rf target/profiling/reth
389
- CARGO_PROFILE_RELEASE_DEBUG=true cargo flamegraph -c "record -o perf.data -F997 --call-graph dwarf,16384 -g" \
390
- --bin reth --profile profiling -- node --chain /home/runner/work/ethrex/ethrex/test_data/genesis-load-test.json --dev \
353
+ cargo build --bin reth --profile profiling
354
+ CARGO_PROFILE_RELEASE_DEBUG=true cargo flamegraph -c "record -o perf.data -F997 --call-graph dwarf,16384 -g" --bin reth --profile profiling -- \
355
+ node --chain /home/runner/work/ethrex/ethrex/test_data/genesis-l2-ci.json --dev \
391
356
--dev.block-time 1000ms --http.port 1729 --txpool.max-pending-txns 100000000 --txpool.max-new-txns 1000000000 \
392
357
--txpool.pending-max-count 100000000 --txpool.pending-max-size 10000000000 --txpool.basefee-max-count 100000000000 \
393
358
--txpool.basefee-max-size 1000000000000 --txpool.queued-max-count 1000000000 >/dev/null &
394
- while [ ! -x "./target/profiling/reth" ]; do
395
- echo "Waiting for reth binary to be ready..."
396
- sleep 10
397
- done
398
359
sleep 30
399
360
echo "Executing load test..."
400
- bash /home/runner/work/ethrex/ethrex/.github/scripts/flamegraph_watcher.sh &&
361
+ (cd /home/runner/work/ethrex/ethrex; . /.github/scripts/flamegraph_watcher.sh)
401
362
echo "Load test finished"
402
363
403
364
- name : Generate SVG
0 commit comments