web-infra-dev / rspack

The fast Rust-based web bundler with webpack-compatible API 🦀️
https://rspack.dev
MIT License
10.04k stars 573 forks source link

perf: reduce source map json stringify #8468

Closed SyMind closed 2 days ago

SyMind commented 3 days ago

Summary

Prevent from json and parse.

TODO sourcemap provide take functions: https://github.com/getsentry/rust-sourcemap/issues/99

Checklist

netlify[bot] commented 3 days ago

Deploy Preview for rspack canceled.

Name Link
Latest commit 39510cfaed78a65e141848c45204b2fce7bb2e67
Latest deploy log https://app.netlify.com/sites/rspack/deploys/673c7f3bcdfa0a0008d65f8f
SyMind commented 3 days ago

!bench

rspack-bot commented 3 days ago

📝 Benchmark detail: Open

Name Base (2024-11-19 bf83b48) Current Change
10000_big_production-mode_disable-minimize + exec 39.8 s ± 1.09 s 39.8 s ± 910 ms -0.03 %
10000_development-mode + exec 1.84 s ± 44 ms 1.81 s ± 46 ms -1.67 %
10000_development-mode_hmr + exec 644 ms ± 10 ms 644 ms ± 1.9 ms -0.09 %
10000_production-mode + exec 2.44 s ± 24 ms 2.42 s ± 31 ms -0.78 %
arco-pro_development-mode + exec 1.8 s ± 69 ms 1.8 s ± 50 ms +0.50 %
arco-pro_development-mode_hmr + exec 430 ms ± 1.5 ms 430 ms ± 1.5 ms +0.03 %
arco-pro_production-mode + exec 3.17 s ± 62 ms 3.1 s ± 54 ms -2.13 %
arco-pro_production-mode_generate-package-json-webpack-plugin + exec 3.2 s ± 43 ms 3.21 s ± 97 ms +0.31 %
threejs_development-mode_10x + exec 1.57 s ± 16 ms 1.58 s ± 19 ms +0.62 %
threejs_development-mode_10x_hmr + exec 778 ms ± 6.1 ms 782 ms ± 10 ms +0.44 %
threejs_production-mode_10x + exec 4.97 s ± 37 ms 4.92 s ± 38 ms -0.92 %
SyMind commented 3 days ago

!bench

rspack-bot commented 3 days ago

📝 Benchmark detail: Open

Name Base (2024-11-19 bf83b48) Current Change
10000_big_production-mode_disable-minimize + exec 39.8 s ± 1.09 s 40.2 s ± 694 ms +0.86 %
10000_development-mode + exec 1.84 s ± 44 ms 1.78 s ± 29 ms -3.53 %
10000_development-mode_hmr + exec 644 ms ± 10 ms 642 ms ± 10 ms -0.38 %
10000_production-mode + exec 2.44 s ± 24 ms 2.38 s ± 13 ms -2.55 %
arco-pro_development-mode + exec 1.8 s ± 69 ms 1.76 s ± 71 ms -1.79 %
arco-pro_development-mode_hmr + exec 430 ms ± 1.5 ms 429 ms ± 1.5 ms -0.27 %
arco-pro_production-mode + exec 3.17 s ± 62 ms 3.08 s ± 43 ms -2.65 %
arco-pro_production-mode_generate-package-json-webpack-plugin + exec 3.2 s ± 43 ms 3.16 s ± 33 ms -1.04 %
threejs_development-mode_10x + exec 1.57 s ± 16 ms 1.59 s ± 22 ms +1.19 %
threejs_development-mode_10x_hmr + exec 778 ms ± 6.1 ms 782 ms ± 4 ms +0.52 %
threejs_production-mode_10x + exec 4.97 s ± 37 ms 4.87 s ± 59 ms -1.97 %