Skip to content

Commit 3d594b9

Browse files
committed
Document aarch64 target_feature options
1 parent 039e1a7 commit 3d594b9

File tree

1 file changed

+63
-0
lines changed

1 file changed

+63
-0
lines changed

src/attributes/codegen.md

+63
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,69 @@ Feature | Implicitly Enables | Description
131131
[`xsaveopt`]: https://www.felixcloutier.com/x86/xsaveopt
132132
[`xsaves`]: https://www.felixcloutier.com/x86/xsaves
133133

134+
#### `aarch64`
135+
136+
This platform requires that `#[target_feature]` is only applied to [`unsafe`
137+
functions][unsafe function].
138+
139+
> ***Note***: The LLVM backend implements the pointer authentication features
140+
> `paca` and `pacg` as one feature. This means that they should both be enabled
141+
> or disabled together if used.
142+
143+
Further documentation on these features can be found in the [ARM Architecture
144+
Reference Manual], or elsewhere on [developer.arm.com].
145+
146+
[ARM Architecture Reference Manual]: https://developer.arm.com/documentation/ddi0487/latest
147+
[developer.arm.com]: https://developer.arm.com
148+
149+
Feature | Implicitly Enables | Feature Name
150+
---------------|--------------------|-------------------
151+
`aes` | `neon` | FEAT_AES - Advanced <abbr title="Single Instruction Multiple Data">SIMD</abbr> AES instructions
152+
`bf16` | | FEAT_BF16 - BFloat16 instructions
153+
`bti` | | FEAT_BTI - Branch Target Identification
154+
`crc` | | FEAT_CRC - CRC32 checksum instructions
155+
`dit` | | FEAT_DIT - Data Independent Timing instructions
156+
`dotprod` | | FEAT_DotProd - Advanced SIMD Int8 dot product instructions
157+
`dpb` | | FEAT_DPB - Data cache clean to point of persistence
158+
`dpb2` | | FEAT_DPB2 - Data cache clean to point of deep persistence
159+
`f32mm` | `sve` | FEAT_F32MM - SVE single-precision FP matrix multiply instruction
160+
`f64mm` | `sve` | FEAT_F64MM - SVE double-precision FP matrix multiply instruction
161+
`fcma` | `neon` | FEAT_FCMA - Floating point complex number support
162+
`fhm` | `fp` | FEAT_FHM - Half-precision FP FMLAL instructions
163+
`flagm` | | FEAT_FlagM - Conditional flag manipulation
164+
`fp` | | FEAT_FP - Floating point extension
165+
`fp16` | `fp` | FEAT_FP16 - Half-precision FP data processing
166+
`frintts` | | FEAT_FRINTTS - Floating-point to int helper instructions
167+
`i8mm` | | FEAT_I8MM - Int8 Matrix Multiplication
168+
`jsconv` | `fp` | FEAT_JSCVT - JavaScript conversion instruction
169+
`lse` | | FEAT_LSE - Large System Extension
170+
`lor` | | FEAT_LOR - Limited Ordering Regions extension
171+
`mte` | | FEAT_MTE - Memory Tagging Extension
172+
`neon` | `fp` | FEAT_AdvSIMD - Advanced SIMD extension
173+
`pan` | | FEAT_PAN - Privileged Access-Never extension
174+
`paca` | | FEAT_PAuth - Pointer Authentication (address authentication)
175+
`pacg` | | FEAT_PAuth - Pointer Authentication (generic authentication)
176+
`pmuv3` | | FEAT_PMUv3 - Performance Monitors extension (v3)
177+
`rand` | | FEAT_RNG - Random Number Generator
178+
`ras` | | FEAT_RAS - Reliability, Availability and Serviceability extension
179+
`rcpc` | | FEAT_LRCPC - Release consistent Processor Consistent
180+
`rcpc2` | `rcpc` | FEAT_LRCPC2 - RcPc with immediate offsets
181+
`rdm` | | FEAT_RDM - Rounding Double Multiply accumulate
182+
`sb` | | FEAT_SB - Speculation Barrier
183+
`sha2` | `neon` | FEAT_SHA1 & FEAT_SHA256 - Advanced SIMD SHA instructions
184+
`sha3` | `neon`, `sha2` | FEAT_SHA512 & FEAT_SHA3 - Advanced SIMD SHA instructions
185+
`sm4` | `neon` | FEAT_SM3 & FEAT_SM4 - Advanced SIMD SM3/4 instructions
186+
`spe` | | FEAT_SPE - Statistical Profiling Extension
187+
`ssbs` | | FEAT_SSBS - Speculative Store Bypass Safe
188+
`sve` | `fp` | FEAT_SVE - Scalable Vector Extension
189+
`sve2` | `sve` | FEAT_SVE2 - Scalable Vector Extension 2
190+
`sve2-aes` | `sve2`, `aes` | FEAT_SVE_AES - SVE AES instructions
191+
`sve2-sm4` | `sve2`, `sm4` | FEAT_SVE_SM4 - SVE SM4 instructions
192+
`sve2-sha3` | `sve2`, `sha3` | FEAT_SVE_SHA3 - SVE SHA3 instructions
193+
`sve2-bitperm` | `sve2` | FEAT_SVE_BitPerm - SVE Bit Permute
194+
`tme` | | FEAT_TME - Transactional Memory Extension
195+
`vh` | | FEAT_VHE - Virtualization Host Extensions
196+
134197
#### `wasm32` or `wasm64`
135198

136199
This platform allows `#[target_feature]` to be applied to both safe and

0 commit comments

Comments
 (0)