mirror of
https://github.com/quickwit-oss/tantivy.git
synced 2026-06-02 00:20:42 +00:00
Adds aarch64-specific SIMD paths (NEON always available on aarch64; SVE gated on nightly + non-Apple target) with routing logic in mod.rs that selects the best available instruction set at runtime.
12 lines
397 B
Rust
12 lines
397 B
Rust
fn main() {
|
|
println!("cargo::rustc-check-cfg=cfg(nightly)");
|
|
let rustc = std::env::var("RUSTC").unwrap_or_else(|_| "rustc".into());
|
|
let output = std::process::Command::new(rustc)
|
|
.arg("--version")
|
|
.output()
|
|
.expect("failed to run rustc");
|
|
if String::from_utf8_lossy(&output.stdout).contains("nightly") {
|
|
println!("cargo:rustc-cfg=nightly");
|
|
}
|
|
}
|