From 1e0f11cfd9897a6acad1e3781b935aa617c1854b Mon Sep 17 00:00:00 2001 From: Hubert Date: Wed, 9 Oct 2024 14:23:37 +0200 Subject: [PATCH] chore: add LTO to release builds + fat LTO profile (#4869) --- Cargo.toml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Cargo.toml b/Cargo.toml index 91666a7e227..2e933bcf3ff 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -250,6 +250,11 @@ strip = true # The FVM relies on catching panics. See: https://github.com/ChainSafe/forest/issues/3153 panic = "unwind" overflow-checks = true +lto = "thin" + +[profile.release-lto-fat] +inherits = "release" +lto = "fat" # These should be refactored (probably removed) in #2984 [features]