Skip to content

Commit dc26334

Browse files
authored
cpufeatures: document unstable target features (#866)
Document which target feature names have not yet been stabilized and are subject to change
1 parent 9ad3448 commit dc26334

File tree

1 file changed

+48
-7
lines changed

1 file changed

+48
-7
lines changed

cpufeatures/src/lib.rs

+48-7
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,54 @@
22
//! as a stopgap until Rust [RFC 2725] adding first-class target feature detection
33
//! macros to `libcore` is implemented.
44
//!
5-
//! Supported target architectures:
6-
//! - `aarch64`: Linux and macOS/M4 only (ARM64 does not support OS-independent feature detection)
7-
//! - Target features: `aes`, `sha2`, `sha3`
8-
//! - `x86`/`x86_64`: OS independent and `no_std`-friendly
9-
//! - Target features: `adx`, `aes`, `avx`, `avx2`, `bmi1`, `bmi2`, `fma`,
10-
//! `mmx`, `pclmulqdq`, `popcnt`, `rdrand`, `rdseed`, `sgx`, `sha`, `sse`,
11-
//! `sse2`, `sse3`, `sse4.1`, `sse4.2`, `ssse3`
5+
//!
6+
//! # Supported target architectures
7+
//!
8+
//! *NOTE: target features with an asterisk are unstable and subject to change
9+
//! to match upstream name changes in the Rust standard library.
10+
//!
11+
//! ## `aarch64`
12+
//!
13+
//! Linux, iOS, and macOS/ARM only (ARM64 does not support OS-independent feature detection)
14+
//!
15+
//! Target features:
16+
//! - `aes`*
17+
//! - `sha2`*
18+
//! - `sha3`*
19+
//!
20+
//! ## `x86`/`x86_64`
21+
//!
22+
//! OS independent and `no_std`-friendly
23+
//!
24+
//! Target features:
25+
//! - `adx`
26+
//! - `aes`
27+
//! - `avx`
28+
//! - `avx2`
29+
//! - `avx512bw`*
30+
//! - `avx512cd`*
31+
//! - `avx512dq`*
32+
//! - `avx512er`*
33+
//! - `avx512f`*
34+
//! - `avx512ifma`*
35+
//! - `avx512pf`*
36+
//! - `avx512vl`*
37+
//! - `bmi1`
38+
//! - `bmi2`
39+
//! - `fma`,
40+
//! - `mmx`
41+
//! - `pclmulqdq`
42+
//! - `popcnt`
43+
//! - `rdrand`
44+
//! - `rdseed`
45+
//! - `sgx`
46+
//! - `sha`
47+
//! - `sse`
48+
//! - `sse2`
49+
//! - `sse3`
50+
//! - `sse4.1`
51+
//! - `sse4.2`
52+
//! - `ssse3`
1253
//!
1354
//! If you would like detection support for a target feature which is not on
1455
//! this list, please [open a GitHub issue][gh].

0 commit comments

Comments
 (0)