From 764aafa88d08ec1d2f67c8ae33f3299e8345d82a Mon Sep 17 00:00:00 2001 From: NotAShelf Date: Tue, 10 Feb 2026 12:55:46 +0300 Subject: [PATCH] meta: optimize builds with experimental compiler flags Signed-off-by: NotAShelf Change-Id: Iec66d57dbad508080af9b00011d4b4276a6a6964 --- .cargo/config.toml | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 .cargo/config.toml diff --git a/.cargo/config.toml b/.cargo/config.toml new file mode 100644 index 0000000..bf15bbc --- /dev/null +++ b/.cargo/config.toml @@ -0,0 +1,27 @@ +[unstable] +build-std = ["std", "panic_abort", "core", "alloc"] + +[build] +rustflags = [ + "-Clto", + "-Zvirtual-function-elimination", + "-Zlocation-detail=none", +] + + +[profile.dev] +opt-level = 0 +debug = 1 +split-debuginfo = "unpacked" +incremental = true + +[profile.release] +opt-level = "z" +debug = false +lto = true +codegen-units = 1 +panic = "abort" +strip = true +incremental = false + +