portable-atomic

crates.io docs.rs license rustc build status build status

Portable atomic types including support for 128-bit atomics, atomic float, etc.

128-bit atomics support (AtomicI128,AtomicU128)

Native 128-bit atomic operations are available on x86_64 (Rust 1.59+), aarch64 (Rust 1.59+), and s390x (nightly only), otherwise the fallback implementation is used.

On x86_64, when the outline-atomics optional feature is not enabled and cmpxchg16b target feature is not enabled at compile-time, this uses the fallback implementation. cmpxchg16b target feature is enabled by default only on macOS.

Optional features

Optional cfg

Related Projects

License

Licensed under either of Apache License, Version 2.0 or MIT license at your option.

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.