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

feat: strip symbols and enable LTO #197

Merged
merged 1 commit into from
Jun 29, 2024
Merged

feat: strip symbols and enable LTO #197

merged 1 commit into from
Jun 29, 2024

Conversation

43081j
Copy link
Contributor

@43081j 43081j commented Jun 28, 2024

Strips symbols from the release build and enables LTO, which results in some reduction in size of the binary.

i've not been around rust in some time so this may be absolute nonsense. if so, feel free to close

as far as i can tell, stripping symbols/debug info is a no-brainer, but LTO can reduce performance in some cases. although the benchmark seemed the same or better locally

i feel like there will be other big savings to have too (without affecting perf), but i need to read up on this stuff more. if you have any ideas, please do let me know and im happy to try them out

Strips symbols from the release build and enables LTO, which results in
some reduction in size of the binary.
Copy link

codspeed-hq bot commented Jun 28, 2024

CodSpeed Performance Report

Merging #197 will improve performances by 8.47%

Comparing 43081j:small (96179e6) with main (834b8fe)

Summary

⚡ 2 improvements

Benchmarks breakdown

Benchmark main 43081j:small Change
resolver[multi-thread] 538.1 µs 496.1 µs +8.47%
resolver[single-thread] 490 µs 449 µs +9.14%

@Boshen
Copy link
Member

Boshen commented Jun 29, 2024

Oh yes! I totally forgot about the napi version requires these, thank you!

@Boshen Boshen merged commit fc9e13c into oxc-project:main Jun 29, 2024
18 checks passed
@Boshen
Copy link
Member

Boshen commented Jun 29, 2024

Thank you, this reduced the binary size from 1.38 MB to 705 kB, and faster too!

@43081j 43081j deleted the small branch June 29, 2024 08:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants