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'#

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. Set this to None to retain host feature detection with LLVM’s default inlining thresholds and SLP recursion depth. "" 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-vectorize to disable loop vectorization or -fno-slp-vectorize to 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 inlining thresholds and SLP recursion depth. None at 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.