From e30d054ca7c08afd46b8b911511da45022025216 Mon Sep 17 00:00:00 2001 From: Calixte Denizet Date: Mon, 19 Oct 2026 10:25:48 +0200 Subject: [PATCH] Compile benchmark JavaScript with Sparkplug on first call CodSpeed's simulation runner warms up before measuring a single call. Use --always-sparkplug so functions exercised during warmup compile immediately rather than waiting for Sparkplug's batch threshold. --- test/benchmarks/vitest.config.mjs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/test/benchmarks/vitest.config.mjs b/test/benchmarks/vitest.config.mjs index 6f920bc9d..49df50b3d 100644 --- a/test/benchmarks/vitest.config.mjs +++ b/test/benchmarks/vitest.config.mjs @@ -100,7 +100,8 @@ export default defineConfig({ include: [], // Compile WebAssembly with TurboFan only to avoid timing variation from // background tier-up from Liftoff. - execArgv: ["--no-liftoff"], + // Compile JavaScript with Sparkplug on first call to avoid delayed batches. + execArgv: ["--no-liftoff", "--always-sparkplug"], benchmark: { include: ["test/benchmarks/**/*.bench.js"], },