From f53e5a971dfa574ed6f76dda506beaf3cacc3537 Mon Sep 17 00:00:00 2001 From: Ian Douglas Scott Date: Fri, 22 Mar 2024 09:50:30 -0700 Subject: [PATCH] Optimize `tiny-skia`, `rustybuzz`, `tty-parser` in dev builds Cosmic-comp seems to spend a lot of CPU time here, particularly in debug builds. The Iced tiny-skia render probably could use some optimization, but it's expected that software rendering without optimization will perform quite poorly. Optimizing just these crates doesn't seem to add measurably to build time but does help noticeably. --- Cargo.toml | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/Cargo.toml b/Cargo.toml index 4a3410a7..263f42c1 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -100,6 +100,15 @@ profile-with-tracy = ["profiling/profile-with-tracy"] [profile.dev] lto = "thin" +[profile.dev.package.tiny-skia] +opt-level = 2 + +[profile.dev.package.rustybuzz] +opt-level = 2 + +[profile.dev.package.ttf-parser] +opt-level = 2 + [profile.fastdebug] debug = true inherits = "release"