Skip to content

Commit 8550a9c

Browse files
goodmanjonathangnzlbg
authored andcommitted
fix sse4a _mm_stream_{ss, sd} tests and docs
1 parent 1f95dfd commit 8550a9c

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

coresimd/src/x86/i686/sse4a.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -55,15 +55,15 @@ pub unsafe fn _mm_insert_si64(x: i64x2, y: i64x2) -> i64x2 {
5555
insertq(x, mem::transmute(y))
5656
}
5757

58-
/// Non-temporal store of `a.1` into `p`.
58+
/// Non-temporal store of `a.0` into `p`.
5959
#[inline(always)]
6060
#[target_feature = "+sse4a"]
6161
#[cfg_attr(test, assert_instr(movntsd))]
6262
pub unsafe fn _mm_stream_sd(p: *mut f64, a: f64x2) {
6363
movntsd(p, a);
6464
}
6565

66-
/// Non-temporal store of `a.3` into `p`.
66+
/// Non-temporal store of `a.0` into `p`.
6767
#[inline(always)]
6868
#[target_feature = "+sse4a"]
6969
#[cfg_attr(test, assert_instr(movntss))]
@@ -125,7 +125,7 @@ mod tests {
125125

126126
sse4a::_mm_stream_sd(d, x);
127127
}
128-
assert_eq!(mem.data[0], 4.0);
128+
assert_eq!(mem.data[0], 3.0);
129129
assert_eq!(mem.data[1], 2.0);
130130
}
131131

@@ -147,7 +147,7 @@ mod tests {
147147

148148
sse4a::_mm_stream_ss(d, x);
149149
}
150-
assert_eq!(mem.data[0], 8.0);
150+
assert_eq!(mem.data[0], 5.0);
151151
assert_eq!(mem.data[1], 2.0);
152152
assert_eq!(mem.data[2], 3.0);
153153
assert_eq!(mem.data[3], 4.0);

0 commit comments

Comments
 (0)