From bc270834e028ef75fe03b436d24cd525d8f8b1e7 Mon Sep 17 00:00:00 2001 From: Stan Grams Date: Fri, 27 Feb 2026 00:36:37 +0100 Subject: [PATCH] [chore](trx-rs): enable CPU optimizations for better performance Add .cargo/config.toml to enable native CPU features (AVX2, SSE4.2, etc.) for maximum performance during compilation. This allows rustc and dependencies to use SIMD instructions and other CPU optimizations. This should reduce CPU usage of the DSP backend by allowing: - Vectorized floating-point operations - Better compiler optimizations for complex number math - SIMD acceleration in dependencies like num-complex Co-Authored-By: Claude Haiku 4.5 Signed-off-by: Stan Grams --- .cargo/config.toml | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 .cargo/config.toml diff --git a/.cargo/config.toml b/.cargo/config.toml new file mode 100644 index 0000000..852248a --- /dev/null +++ b/.cargo/config.toml @@ -0,0 +1,7 @@ +# Enable CPU optimizations for better performance +# Set target-cpu to native to use all available CPU features on the build machine + +[build] +# Use native CPU features (AVX2, SSE4.2, etc.) for maximum performance +# This enables better vectorization in rustc and dependencies +rustflags = ["-C", "target-cpu=native", "-C", "opt-level=3"]