Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

perf(es/minifier): Use rope-like structure for the name mangler #6661

Merged
merged 12 commits into from Dec 15, 2022

Conversation

kdy1
Copy link
Member

@kdy1 kdy1 commented Dec 15, 2022

Description:


Profiling result

I profiled only name mangler.

Gnuplot not found, using plotters backend
Benchmarking es/minify/libraries/antd
Benchmarking es/minify/libraries/antd: Warming up for 3.0000 s
Benchmarking es/minify/libraries/antd: Collecting 10 samples in estimated 6.0289 s (30 iterations)
Benchmarking es/minify/libraries/antd: Analyzing
es/minify/libraries/antd
                        time:   [199.41 ms 200.82 ms 202.28 ms]
                        change: [-5.6785% -3.6904% -1.8832%] (p = 0.00 < 0.05)
                        Performance has improved.
Benchmarking es/minify/libraries/d3
Benchmarking es/minify/libraries/d3: Warming up for 3.0000 s
Benchmarking es/minify/libraries/d3: Collecting 10 samples in estimated 6.8704 s (165 iterations)
Benchmarking es/minify/libraries/d3: Analyzing
es/minify/libraries/d3  time:   [39.144 ms 39.570 ms 40.032 ms]
                        change: [-11.290% -9.6763% -8.0153%] (p = 0.00 < 0.05)
                        Performance has improved.
Found 1 outliers among 10 measurements (10.00%)
  1 (10.00%) high mild
Benchmarking es/minify/libraries/echarts
Benchmarking es/minify/libraries/echarts: Warming up for 3.0000 s

Warning: Unable to complete 10 samples in 5.0s. You may wish to increase target time to 7.6s or enable flat sampling.
Benchmarking es/minify/libraries/echarts: Collecting 10 samples in estimated 7.6106 s (55 iterations)
Benchmarking es/minify/libraries/echarts: Analyzing
es/minify/libraries/echarts
                        time:   [137.66 ms 139.70 ms 141.25 ms]
                        change: [-16.807% -15.665% -14.492%] (p = 0.00 < 0.05)
                        Performance has improved.
Benchmarking es/minify/libraries/jquery
Benchmarking es/minify/libraries/jquery: Warming up for 3.0000 s
Benchmarking es/minify/libraries/jquery: Collecting 10 samples in estimated 5.2903 s (385 iterations)
Benchmarking es/minify/libraries/jquery: Analyzing
es/minify/libraries/jquery
                        time:   [13.699 ms 13.826 ms 13.960 ms]
                        change: [-10.927% -4.5999% +0.3475%] (p = 0.19 > 0.05)
                        No change in performance detected.
Found 3 outliers among 10 measurements (30.00%)
  2 (20.00%) low mild
  1 (10.00%) high mild
Benchmarking es/minify/libraries/lodash
Benchmarking es/minify/libraries/lodash: Warming up for 3.0000 s
Benchmarking es/minify/libraries/lodash: Collecting 10 samples in estimated 5.4415 s (385 iterations)
Benchmarking es/minify/libraries/lodash: Analyzing
es/minify/libraries/lodash
                        time:   [13.607 ms 13.774 ms 13.959 ms]
                        change: [-11.005% -7.0837% -3.4633%] (p = 0.00 < 0.05)
                        Performance has improved.
Benchmarking es/minify/libraries/moment
Benchmarking es/minify/libraries/moment: Warming up for 3.0000 s
Benchmarking es/minify/libraries/moment: Collecting 10 samples in estimated 5.2260 s (605 iterations)
Benchmarking es/minify/libraries/moment: Analyzing
es/minify/libraries/moment
                        time:   [8.2814 ms 8.5046 ms 8.7380 ms]
                        change: [-4.8923% -0.2800% +3.4316%] (p = 0.91 > 0.05)
                        No change in performance detected.
Benchmarking es/minify/libraries/react
Benchmarking es/minify/libraries/react: Warming up for 3.0000 s
Benchmarking es/minify/libraries/react: Collecting 10 samples in estimated 5.1175 s (1650 iterations)
Benchmarking es/minify/libraries/react: Analyzing
es/minify/libraries/react
                        time:   [2.9310 ms 2.9575 ms 2.9858 ms]
                        change: [-10.242% -4.5445% +0.0259%] (p = 0.14 > 0.05)
                        No change in performance detected.
Found 1 outliers among 10 measurements (10.00%)
  1 (10.00%) high mild
Benchmarking es/minify/libraries/terser
Benchmarking es/minify/libraries/terser: Warming up for 3.0000 s
Benchmarking es/minify/libraries/terser: Collecting 10 samples in estimated 6.3674 s (165 iterations)
Benchmarking es/minify/libraries/terser: Analyzing
es/minify/libraries/terser
                        time:   [37.407 ms 37.525 ms 37.725 ms]
                        change: [-5.1624% -3.7781% -2.7200%] (p = 0.00 < 0.05)
                        Performance has improved.
Benchmarking es/minify/libraries/three
Benchmarking es/minify/libraries/three: Warming up for 3.0000 s
Benchmarking es/minify/libraries/three: Collecting 10 samples in estimated 6.6725 s (110 iterations)
Benchmarking es/minify/libraries/three: Analyzing
es/minify/libraries/three
                        time:   [59.542 ms 59.845 ms 60.335 ms]
                        change: [-13.095% -11.341% -10.142%] (p = 0.00 < 0.05)
                        Performance has improved.
Benchmarking es/minify/libraries/typescript
Benchmarking es/minify/libraries/typescript: Warming up for 3.0000 s
Benchmarking es/minify/libraries/typescript: Collecting 10 samples in estimated 6.3900 s (20 iterations)
Benchmarking es/minify/libraries/typescript: Analyzing
es/minify/libraries/typescript
                        time:   [317.06 ms 318.84 ms 320.99 ms]
                        change: [-5.8092% -4.2215% -2.9126%] (p = 0.00 < 0.05)
                        Performance has improved.
Found 2 outliers among 10 measurements (20.00%)
  2 (20.00%) high mild
Benchmarking es/minify/libraries/victory
Benchmarking es/minify/libraries/victory: Warming up for 3.0000 s
Benchmarking es/minify/libraries/victory: Collecting 10 samples in estimated 9.3314 s (110 iterations)
Benchmarking es/minify/libraries/victory: Analyzing
es/minify/libraries/victory
                        time:   [83.837 ms 84.918 ms 86.355 ms]
                        change: [-1.5848% -0.0605% +1.6815%] (p = 0.94 > 0.05)
                        No change in performance detected.
Found 1 outliers among 10 measurements (10.00%)
  1 (10.00%) high mild
Benchmarking es/minify/libraries/vue
Benchmarking es/minify/libraries/vue: Warming up for 3.0000 s
Benchmarking es/minify/libraries/vue: Collecting 10 samples in estimated 5.5333 s (330 iterations)
Benchmarking es/minify/libraries/vue: Analyzing
es/minify/libraries/vue time:   [16.684 ms 16.975 ms 17.274 ms]
                        change: [-6.4612% -4.4508% -2.3520%] (p = 0.00 < 0.05)
                        Performance has improved.

@kdy1 kdy1 added this to the Planned milestone Dec 15, 2022
@kdy1 kdy1 self-assigned this Dec 15, 2022
@kdy1 kdy1 changed the title Perf before analysis perf(es/minifier): Use rope-like structure for the name mangler Dec 15, 2022
Copy link
Member Author

@kdy1 kdy1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

swc-bump:

  • swc_ecma_minifier

@kdy1 kdy1 marked this pull request as ready for review December 15, 2022 08:37
@kdy1 kdy1 enabled auto-merge (squash) December 15, 2022 08:37
Copy link
Collaborator

@swc-bot swc-bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Automated review comment generated by auto-rebase script

@kdy1 kdy1 merged commit cb4173a into swc-project:main Dec 15, 2022
@kdy1 kdy1 deleted the perf-before-analysis branch December 15, 2022 09:31
@kdy1 kdy1 modified the milestones: Planned, 1.3.24 Dec 21, 2022
@swc-project swc-project locked as resolved and limited conversation to collaborators Jan 20, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants