@@ -4,46 +4,46 @@ macro_rules! impl_integer_reductions {
4
4
where
5
5
Self : crate :: LanesAtMost32
6
6
{
7
- /// Horizontal wrapping add. Computes the sum of the lanes of the vector, with wrapping addition.
7
+ /// Horizontal wrapping add. Returns the sum of the lanes of the vector, with wrapping addition.
8
8
#[ inline]
9
9
pub fn wrapping_sum( self ) -> $scalar {
10
10
unsafe { crate :: intrinsics:: simd_reduce_add_ordered( self , 0 ) }
11
11
}
12
12
13
- /// Horizontal wrapping multiply. Computes the product of the lanes of the vector, with wrapping multiplication.
13
+ /// Horizontal wrapping multiply. Returns the product of the lanes of the vector, with wrapping multiplication.
14
14
#[ inline]
15
15
pub fn wrapping_product( self ) -> $scalar {
16
16
unsafe { crate :: intrinsics:: simd_reduce_mul_ordered( self , 1 ) }
17
17
}
18
18
19
- /// Horizontal bitwise "and". Computes the cumulative bitwise "and" across the lanes of
19
+ /// Horizontal bitwise "and". Returns the cumulative bitwise "and" across the lanes of
20
20
/// the vector.
21
21
#[ inline]
22
22
pub fn horizontal_and( self ) -> $scalar {
23
23
unsafe { crate :: intrinsics:: simd_reduce_and( self ) }
24
24
}
25
25
26
- /// Horizontal bitwise "or". Computes the cumulative bitwise "or" across the lanes of
26
+ /// Horizontal bitwise "or". Returns the cumulative bitwise "or" across the lanes of
27
27
/// the vector.
28
28
#[ inline]
29
29
pub fn horizontal_or( self ) -> $scalar {
30
30
unsafe { crate :: intrinsics:: simd_reduce_or( self ) }
31
31
}
32
32
33
- /// Horizontal bitwise "xor". Computes the cumulative bitwise "xor" across the lanes of
33
+ /// Horizontal bitwise "xor". Returns the cumulative bitwise "xor" across the lanes of
34
34
/// the vector.
35
35
#[ inline]
36
36
pub fn horizontal_xor( self ) -> $scalar {
37
37
unsafe { crate :: intrinsics:: simd_reduce_xor( self ) }
38
38
}
39
39
40
- /// Horizontal maximum. Computes the maximum lane in the vector.
40
+ /// Horizontal maximum. Returns the maximum lane in the vector.
41
41
#[ inline]
42
42
pub fn horizontal_max( self ) -> $scalar {
43
43
unsafe { crate :: intrinsics:: simd_reduce_max( self ) }
44
44
}
45
45
46
- /// Horizontal minimum. Computes the minimum lane in the vector.
46
+ /// Horizontal minimum. Returns the minimum lane in the vector.
47
47
#[ inline]
48
48
pub fn horizontal_min( self ) -> $scalar {
49
49
unsafe { crate :: intrinsics:: simd_reduce_min( self ) }
@@ -59,7 +59,7 @@ macro_rules! impl_float_reductions {
59
59
Self : crate :: LanesAtMost32
60
60
{
61
61
62
- /// Horizontal add. Computes the sum of the lanes of the vector.
62
+ /// Horizontal add. Returns the sum of the lanes of the vector.
63
63
#[ inline]
64
64
pub fn sum( self ) -> $scalar {
65
65
// LLVM sum is inaccurate on i586
@@ -70,7 +70,7 @@ macro_rules! impl_float_reductions {
70
70
}
71
71
}
72
72
73
- /// Horizontal multiply. Computes the sum of the lanes of the vector.
73
+ /// Horizontal multiply. Returns the product of the lanes of the vector.
74
74
#[ inline]
75
75
pub fn product( self ) -> $scalar {
76
76
// LLVM product is inaccurate on i586
@@ -81,7 +81,7 @@ macro_rules! impl_float_reductions {
81
81
}
82
82
}
83
83
84
- /// Horizontal maximum. Computes the maximum lane in the vector.
84
+ /// Horizontal maximum. Returns the maximum lane in the vector.
85
85
///
86
86
/// Returns values based on equality, so a vector containing both `0.` and `-0.` may
87
87
/// return either. This function will not return `NaN` unless all lanes are `NaN`.
@@ -90,7 +90,7 @@ macro_rules! impl_float_reductions {
90
90
unsafe { crate :: intrinsics:: simd_reduce_max( self ) }
91
91
}
92
92
93
- /// Horizontal minimum. Computes the minimum lane in the vector.
93
+ /// Horizontal minimum. Returns the minimum lane in the vector.
94
94
///
95
95
/// Returns values based on equality, so a vector containing both `0.` and `-0.` may
96
96
/// return either. This function will not return `NaN` unless all lanes are `NaN`.
0 commit comments