perf: optimize release profile for smaller binary size

Configure release profile with aggressive size optimizations:
- Set opt-level to 'z' for minimum binary size
- Enable LTO for better optimization across crates
- Strip debug info to reduce final binary size
- Use panic=abort to eliminate unwinding machinery
- Reduce codegen units to 1 for maximum optimization
- Keep overflow checks for safety in production
This commit is contained in:
2025-12-11 11:51:30 -06:00
parent 24c2c2b3c5
commit a9e3ab8337

View File

@@ -18,3 +18,11 @@ tokio = { version = "1", features = ["macros"] }
tokio-stream = "0.1.17"
tracing = "0.1"
tracing-subscriber = { version = "0.3", features = ["env-filter"] }
[profile.release]
opt-level = "z"
lto = true
strip = "debuginfo"
panic = "abort"
codegen-units = 1
overflow-checks = true