std::experimental::simd_abi::fixed_size
来自 cppreference.com
< cpp | experimental | simd
在头文件 <experimental/simd> 中定义 |
||
template< int N > struct fixed_size {}; |
(并行 TS v2) | |
The simd_abi::fixed_size<N> tag type ensures data-parallel types to store and manipulate N
elements (i.e. simd<T, simd_abi::fixed_size<N>>::size() returns N
). An implementation shall support at least all N
∈ [
1,
32]
. Additionally, for every supported simd<T, Abi>, where Abi
is an implementation-defined ABI tag, N = simd<T, Abi>::size() shall be supported.
[edit] Notes
An implementation may choose to forego ABI compatibility between differently compiled translation units for simd
and simd_mask
instantiations using the same simd_abi::fixed_size<N> tag. Otherwise, the efficiency of simd<T, Abi> is likely to be better than simd<T, fixed_size<simd_size_v<T, Abi>>> (with Abi
not an instance of simd_abi::fixed_size).
[edit] Example
本节内容不完整 原因:没有示例 |
[edit] 另请参阅
(并行 TS v2) |
fixed 保证支持的最大元素数 (常量) |
(并行 TS v2) |
用于存储单个元素的标签类型 (typedef) |
(并行 TS v2) |
确保 ABI 兼容性的标签类型 (别名模板) |
(并行 TS v2) |
效率最高的标签类型 (别名模板) |
(并行 TS v2) |
获取给定元素类型和元素数量的 ABI 类型 (类模板) |