Skip to content

Comments

Make threadpool optional#7

Merged
reu merged 1 commit intoreu:masterfrom
petoknm:optional-threadpool
Jan 30, 2025
Merged

Make threadpool optional#7
reu merged 1 commit intoreu:masterfrom
petoknm:optional-threadpool

Conversation

@petoknm
Copy link
Contributor

@petoknm petoknm commented Jan 25, 2025

I am using touche in single threaded mode and I was expecting that my config (below) would eliminate the code from threadpool crate if unused, but it was not able to completely remove it. I assume this was because of some use of it in Server type.

[profile.release]
opt-level = "z"
lto = true
codegen-units = 1

With this MR, I was able to fully eliminate threadpool crate's code from my final binary.

Copy link
Owner

@reu reu left a comment

Choose a reason for hiding this comment

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

That's some excellent work! Just a requesting a minor change but besides that this is ready to go! Thanks!

@petoknm petoknm force-pushed the optional-threadpool branch from e47096e to a7d02c3 Compare January 29, 2025 09:47
@petoknm
Copy link
Contributor Author

petoknm commented Jan 29, 2025

The CI jobs scripts might need a tweak, currently they use --no-default-features --features server.

@reu reu merged commit c2359a5 into reu:master Jan 30, 2025
3 of 12 checks passed
@reu
Copy link
Owner

reu commented Jan 30, 2025

Thanks a lot @petoknm, looks great!

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