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

Optimize compute units via compiler flags #23

Open
armaniferrante opened this issue Nov 27, 2021 · 2 comments
Open

Optimize compute units via compiler flags #23

armaniferrante opened this issue Nov 27, 2021 · 2 comments

Comments

@armaniferrante
Copy link

The following Cargo.toml settings have been shown to reduce compute units

[profile.release]
lto = "fat"
codegen-units = 1

[profile.release.build-override]
opt-level = 3
incremental = false
codegen-units = 1

Example here project-serum/serum-dex#159

@ellttBen
Copy link
Contributor

ellttBen commented Jun 8, 2022

@armaniferrante is this still relevant? If so I don't understand why this isn't the default setting. Is there a hidden tradeoff?

@armaniferrante
Copy link
Author

Slower compile times is the only one I'm aware of.

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

No branches or pull requests

2 participants