warp.config.cpu_compiler_flags#
- warp.config.cpu_compiler_flags: str | None = '-march=native -mllvm=-inline-threshold=9000 -mllvm=-inline-cold-callsite-threshold=3000 -mllvm=-slp-recursion-max-depth=4 -mllvm=-undef-reg-clearance=4294967295'#
Flags controlling CPU kernel compilation.
The default detects host CPU features, raises LLVM’s inlining thresholds, and limits SLP recursion depth to four instead of LLVM’s default 12. On x86-64, it also favors clearing unused scalar-conversion operands to avoid denormal penalties in unused SIMD lanes. This does not flush valid subnormal values. Set this to
Noneto retain host feature detection with LLVM’s default optimization settings.""compiles for a generic CPU target. A flag string can include-march=native, Clang frontend flags, and LLVM arguments in either-mllvm <option>or-mllvm=<option>form. Use-fno-vectorizeto disable loop vectorization or-fno-slp-vectorizeto disable SLP vectorization for a module.The
"cpu_compiler_flags"module option replaces this global string for that module. Use"-march=native"to keep host feature detection while using LLVM’s default optimization settings.Noneat the module level inherits the global setting.The resolved flag string is part of the module cache key. LLVM options are a power-user feature with process-wide caveats; see LLVM Options for CPU Compilation.