mirror of
https://github.com/rust-lang/rust-analyzer
synced 2024-12-24 12:03:31 +00:00
f92bfb5807
Co-authored-by: bjorn3 <bjorn3@users.noreply.github.com> Override miniz_oxide to build it with optimizations Building this crate with optimizations decreases the gzipping part of `cargo xtask dist` from `30-40s` down to `3s`, the overhead for `rustc` to apply optimizations is miserable on this background
43 lines
1.3 KiB
TOML
43 lines
1.3 KiB
TOML
[workspace]
|
|
members = [ "crates/*", "xtask/" ]
|
|
|
|
[profile.dev]
|
|
# disabling debug info speeds up builds a bunch,
|
|
# and we don't rely on it for debugging that much.
|
|
debug = 0
|
|
|
|
[profile.release]
|
|
incremental = true
|
|
debug = 0 # set this to 1 or 2 to get more useful backtraces in debugger
|
|
|
|
# ideally, we would use `build-override` here, but some crates are also
|
|
# needed at run-time and we end up compiling them twice
|
|
[profile.release.package.proc-macro2]
|
|
opt-level = 0
|
|
[profile.release.package.quote]
|
|
opt-level = 0
|
|
[profile.release.package.syn]
|
|
opt-level = 0
|
|
[profile.release.package.serde_derive]
|
|
opt-level = 0
|
|
[profile.release.package.chalk-derive]
|
|
opt-level = 0
|
|
[profile.release.package.salsa-macros]
|
|
opt-level = 0
|
|
[profile.release.package.tracing-attributes]
|
|
opt-level = 0
|
|
[profile.release.package.xtask]
|
|
opt-level = 0
|
|
|
|
# Gzipping the artifacts is up to 10 times faster with optimizations (`cargo xtask dist`).
|
|
# `miniz_oxide` is the direct dependency of `flate2` which does all the heavy lifting
|
|
[profile.dev.package.miniz_oxide]
|
|
opt-level = 3
|
|
|
|
[patch.'crates-io']
|
|
# rowan = { path = "../rowan" }
|
|
|
|
[patch.'https://github.com/rust-lang/chalk.git']
|
|
# chalk-solve = { path = "../chalk/chalk-solve" }
|
|
# chalk-rust-ir = { path = "../chalk/chalk-rust-ir" }
|
|
# chalk-ir = { path = "../chalk/chalk-ir" }
|