diff --git a/README.md b/README.md index e946b54a5d..0c54cf4eb4 100644 --- a/README.md +++ b/README.md @@ -191,13 +191,7 @@ assert!(matches.matched(6)); ### Usage: enable SIMD optimizations -This crate provides an `unstable` feature that can only be enabled on nightly -Rust. When this feature is enabled, the regex crate will use SIMD optimizations -if your CPU supports them. No additional compile time flags are required; the -regex crate will detect your CPU support at runtime. - -When `std::arch` becomes stable, then these optimizations will be enabled -automatically. +SIMD optimizations are enabled automatically on Rust stable 1.27 and newer. ### Usage: a regular expression parser diff --git a/build.rs b/build.rs index 817629d656..9440ab92d7 100644 --- a/build.rs +++ b/build.rs @@ -15,13 +15,9 @@ fn main() { } fn enable_simd_optimizations(version: &str) { - // If we're using nightly Rust, then we can enable vector optimizations. - // Note that these aren't actually activated unless the `unstable` feature - // is enabled. - // - // We also don't activate these if we've explicitly disabled auto - // optimizations. Disabling auto optimizations is intended for use in - // tests, so that we can reliably test fallback implementations. + // We don't activate SIMD optimizations these if we've explicitly disabled + // them. Disabling auto optimizations is intended for use in tests, so that + // we can reliably test fallback implementations. if env::var_os("CARGO_CFG_REGEX_DISABLE_AUTO_OPTIMIZATIONS").is_some() { return; }