Files
WhispAssist/.cargo/config.toml
T
iamdoubz d89b99db6c fix(build): restore /O2 /DNDEBUG for native deps clobbered by cmake-rs on MSVC
cmake-rs hardcodes opt_level(0) and replaces CMake's Release C flags, so
ggml/whisper.cpp compiled at /Od — root cause of the W1 CPU-pathology
(RTF ~20) in docs/benchmarks/2026-07-parakeet-vs-whisper.md. cc-rs appends
env CFLAGS/CXXFLAGS last, restoring optimization for all native deps.
2026-07-16 08:14:08 -05:00

11 lines
587 B
TOML

# Fix: whisper.cpp (whisper-rs-sys) is configured by the cmake crate, which
# hardcodes opt_level(0) and overwrites CMake's default MSVC Release flags
# (/O2 /Ob2 /DNDEBUG) with unoptimized ones — ggml's CPU kernels were compiled
# at /Od with asserts on, making CPU-only transcription ~40x slower than real
# time (bench finding W1, docs/benchmarks/2026-07-parakeet-vs-whisper.md).
# cc-rs appends these env flags after its own, so they win for every native
# dep. MSVC-only flags are fine: WhispAssist is a Windows-native app.
[env]
CFLAGS = "/O2 /DNDEBUG"
CXXFLAGS = "/O2 /DNDEBUG"