Avatar for the webpack user
webpack
tapable
BlogDocsChangelog

fix(perf): cache lengths/locals in more hot loops

#225Merged
Comparing
claude/test-perf-improvements-JXkUd
(
1729bb4
) with
main
(
9e9ae4d
)
CodSpeed Performance Gauge
0%
Untouched
92

Benchmarks

92 total
hook-compile: AsyncParallelHook, 5 taps + first callAsync
benchmark/cases/hook-compile/index.bench.mjs
CodSpeed Performance Gauge
+3%
172.1 µs166.6 µs
hook-compile: AsyncParallelBailHook, 5 taps + first callAsync
benchmark/cases/hook-compile/index.bench.mjs
CodSpeed Performance Gauge
+2%
405.2 µs396.8 µs
hook-compile: AsyncSeriesWaterfallHook, 5 taps + first callAsync
benchmark/cases/hook-compile/index.bench.mjs
CodSpeed Performance Gauge
+2%
159.9 µs156.7 µs
hook-compile: AsyncSeriesBailHook, 5 taps + first callAsync
benchmark/cases/hook-compile/index.bench.mjs
CodSpeed Performance Gauge
+2%
158.8 µs155.9 µs
hook-compile: AsyncSeriesHook, 5 taps + first callAsync
benchmark/cases/hook-compile/index.bench.mjs
CodSpeed Performance Gauge
+2%
154.7 µs152.3 µs
hook-compile: SyncWaterfallHook, 5 taps + first call
benchmark/cases/hook-compile/index.bench.mjs
CodSpeed Performance Gauge
+1%
157.2 µs156.1 µs
hook-compile: SyncHook, 5 taps + first call
benchmark/cases/hook-compile/index.bench.mjs
CodSpeed Performance Gauge
+1%
146.2 µs145.3 µs
hook-compile: SyncLoopHook, 5 taps + first call
benchmark/cases/hook-compile/index.bench.mjs
CodSpeed Performance Gauge
+1%
148.4 µs147.5 µs
async-series-hook: promise, 5 sync taps
benchmark/cases/async-series-hook/index.bench.mjs
CodSpeed Performance Gauge
+1%
266.6 µs265.1 µs
hook-map: for(new key) x 10, no interceptors
benchmark/cases/hook-map/index.bench.mjs
CodSpeed Performance Gauge
0%
44.7 µs44.5 µs
hook-map: for(new key) x 10, 1 interceptor
benchmark/cases/hook-map/index.bench.mjs
CodSpeed Performance Gauge
0%
50.8 µs50.7 µs
sync-loop-hook: 3 taps, 0 reloops
benchmark/cases/sync-loop-hook/index.bench.mjs
CodSpeed Performance Gauge
0%
62.6 µs62.4 µs
tap-registration: SyncHook tap x 10, with stages
benchmark/cases/tap-registration/index.bench.mjs
CodSpeed Performance Gauge
0%
85.3 µs85 µs
hook-compile: SyncBailHook, 5 taps + first call
benchmark/cases/hook-compile/index.bench.mjs
CodSpeed Performance Gauge
0%
387.7 µs386.6 µs
interceptors-sync: 5 taps, call + tap interceptor
benchmark/cases/interceptors-sync/index.bench.mjs
CodSpeed Performance Gauge
0%
40.2 µs40.1 µs
async-series-loop-hook: 10 taps, 0 reloops
benchmark/cases/async-series-loop-hook/index.bench.mjs
CodSpeed Performance Gauge
0%
74.8 µs74.7 µs
async-series-loop-hook: 3 taps, 2 reloops
benchmark/cases/async-series-loop-hook/index.bench.mjs
CodSpeed Performance Gauge
0%
72.3 µs72.2 µs
interceptors-async: series, 5 sync taps, call interceptor
benchmark/cases/interceptors-async/index.bench.mjs
CodSpeed Performance Gauge
0%
55.6 µs55.5 µs
interceptors-async: series, 5 sync taps, tap interceptor
benchmark/cases/interceptors-async/index.bench.mjs
CodSpeed Performance Gauge
0%
57.8 µs57.7 µs
hook-map: for(new key) x 10, 3 interceptors
benchmark/cases/hook-map/index.bench.mjs
CodSpeed Performance Gauge
0%
52.6 µs52.6 µs
async-series-hook: callAsync, 20 sync taps
benchmark/cases/async-series-hook/index.bench.mjs
CodSpeed Performance Gauge
0%
63.6 µs63.5 µs
async-series-hook: callAsync, 1 sync taps
benchmark/cases/async-series-hook/index.bench.mjs
CodSpeed Performance Gauge
0%
53.8 µs53.8 µs
async-series-hook: promise, 5 async taps
benchmark/cases/async-series-hook/index.bench.mjs
CodSpeed Performance Gauge
0%
463.7 µs463.4 µs
async-series-loop-hook: 3 taps, 0 reloops
benchmark/cases/async-series-loop-hook/index.bench.mjs
CodSpeed Performance Gauge
0%
57.3 µs57.2 µs
interceptors-async: parallel, 5 async taps, no interceptors
benchmark/cases/interceptors-async/index.bench.mjs
CodSpeed Performance Gauge
0%
132.1 µs132 µs

Commits

Click on a commit to change the comparison range
Base
main
9e9ae4d
-51.64%
fix(perf): cache lengths/locals in more hot loops
0f7d7e4
21 hours ago
by claude
+51.64%
Revert "fix(perf): cache lengths/locals in more hot loops"
2c58627
21 hours ago
by claude
+0.13%
fix(perf): drop per-compile allocations in args() and init()
2678f47
21 hours ago
by claude
-23.18%
fix(perf): drop more per-compile and per-insert allocations
4355011
20 hours ago
by claude
-0.12%
fix(perf): split _insert walk so stage-only path has no overhead
5b2bb30
20 hours ago
by claude
+23.32%
Revert "fix(perf): drop more per-compile and per-insert allocations"
1729bb4
19 hours ago
by claude
© 2026 CodSpeed Technology
Home Terms Privacy Docs