Repository navigation
Commit 5a15f4b
committed
perf(core): end idle workers after 500ms instead of a second
A worker only ended a second after its last task, so the `jsx-ast`
workers and their heaps (~800MB on the Node.js docs) were still there
while the main thread bundled the site, which is when the build peaked.
They now end half a second after running out of work: soon enough to be
gone while the site is bundled, but not in the short gaps between two
generators, where ending and starting workers again costs time.
On Node core's build with 4 threads on Node 26, the peak goes from
~2.31GB to ~1.91GB.
Assisted-by: Claude Opus 5.5 <noreply@anthropic.com>1 parent 257e25b commit 5a15f4b
1 file changed
Lines changed: 4 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
24 | 24 | | |
25 | 25 | | |
26 | 26 | | |
27 | | - | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
28 | 31 | | |
29 | 32 | | |
30 | 33 | | |
| |||
0 commit comments