diff --git a/.travis.yml b/.travis.yml index 29afb99..3d239ba 100644 --- a/.travis.yml +++ b/.travis.yml @@ -11,14 +11,10 @@ env: - - CARGO_CFG_HTTPARSE_DISABLE_SIMD=1 - CARGO_CFG_HTTPARSE_DISABLE_SIMD_COMPILETIME=1 RUSTFLAGS="-C target_feature=+sse4.2" - #- CARGO_CFG_HTTPARSE_DISABLE_SIMD_COMPILETIME=1 RUSTFLAGS="-C target_feature=+avx2" - #- CARGO_CFG_HTTPARSE_DISABLE_SIMD_COMPILETIME=1 RUSTFLAGS="-C target_feature=+sse4.2,+avx2" - RUSTFLAGS="-C target_feature=+sse4.2" - #- RUSTFLAGS="-C target_feature=+avx2" - #- RUSTFLAGS="-C target_feature=+sse4.2,+avx2" matrix: - #fast_finish: true + fast_finish: true include: - rust: 1.10.0 # minimum Rust version script: # don't run tests, since dev-dependencies don't build on 1.10 diff --git a/src/lib.rs b/src/lib.rs index 91379a8..471cdc2 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -10,7 +10,15 @@ //! parsing internals use an `Iterator` instead of direct indexing, while //! skipping bounds checks. //! -//! The speed is faster than picohttpparser, when SIMD is not available. +//! With Rust 1.27.0 or later, support for SIMD is enabled automatically. +//! If building an executable to be run on multiple platforms, and thus +//! not passing `target_feature` or `target_cpu` flags to the compiler, +//! runtime detection can still detect SSE4.2 or AVX2 support to provide +//! massive wins. +//! +//! If compiling for a specific target, remembering to include +//! `-C target_cpu=native` allows the detection to become compile time checks, +//! making it *even* faster. #[cfg(feature = "std")] extern crate std as core;