perf(module-concat): cheapen bailout reason generation#13609
perf(module-concat): cheapen bailout reason generation#13609LingyuCoder wants to merge 4 commits intomainfrom
Conversation
|
📝 Benchmark detail: Open
|
Merging this PR will improve performance by 11.18%
Performance Changes
Comparing Footnotes
|
Rsdoctor Bundle Diff Analysis
Found 6 projects in monorepo, 6 projects with changes. 📊 Quick Summary
📋 Detailed Reports (Click to expand)📁 popular-libsPath:
📦 Download Diff Report: popular-libs Bundle Diff 📁 react-10kPath:
📦 Download Diff Report: react-10k Bundle Diff 📁 react-1kPath:
📦 Download Diff Report: react-1k Bundle Diff 📁 romePath:
📦 Download Diff Report: rome Bundle Diff 📁 react-5kPath:
📦 Download Diff Report: react-5k Bundle Diff 📁 ui-componentsPath:
📦 Download Diff Report: ui-components Bundle Diff Generated by Rsdoctor GitHub Action |
📦 Binary Size-limit
🎉 Size decreased by 10.97KB from 49.26MB to 49.25MB (⬇️0.02%) |
|
📝 Benchmark detail: Open
|
Summary
BailoutWitnessmodeltry_to_addbailouts record one deterministic witness for missing chunks, non-module references, cross-chunk importers, unsupported syntax importers, and runtime-dependent importersWhy
module_concatenation_plugin::try_to_addwas doing extra hot-path work to build complete bailout messages, including collecting whole candidate sets, sorting them, and formatting aggregate strings. For bailout-heavy concatenation cases that overhead is unnecessary because a single sufficient witness is enough to explain the bailout.Impact
Validation
cargo fmt --all --checkcargo lintpnpm run build:cli:devpnpm run test:rspnpm run test -t "side-effects-optimization"pnpm run test -t "scope-hoisting-multi"Notes
Checked: ... rust@create_concatenate_modulebecause CodSpeed reported an unknown environment, so no strict local numeric before/after claim is included herepnpm run test:unitwas not stable locally: repeated runs failed in different places (builtin-swc-loadertimeout,Serial.test.jsworker exit,Config.part1.test.jsafterAll timeout), which looks more like suite/harness flakiness than a stable regression from this Rust-only change