Skip to content

Commit

Permalink
[breaking change] _mm256_store_p{d, s} take a mut pointer
Browse files Browse the repository at this point in the history
Closes rust-lang#743 .
  • Loading branch information
gnzlbg committed May 9, 2019
1 parent c9d2df6 commit f5691cc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions crates/core_arch/src/x86/avx.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1634,7 +1634,7 @@ pub unsafe fn _mm256_load_pd(mem_addr: *const f64) -> __m256d {
#[cfg_attr(test, assert_instr(vmovaps))] // FIXME vmovapd expected
#[stable(feature = "simd_x86", since = "1.27.0")]
#[allow(clippy::cast_ptr_alignment)]
pub unsafe fn _mm256_store_pd(mem_addr: *const f64, a: __m256d) {
pub unsafe fn _mm256_store_pd(mem_addr: *mut f64, a: __m256d) {
*(mem_addr as *mut __m256d) = a;
}

Expand Down Expand Up @@ -1664,7 +1664,7 @@ pub unsafe fn _mm256_load_ps(mem_addr: *const f32) -> __m256 {
#[cfg_attr(test, assert_instr(vmovaps))]
#[stable(feature = "simd_x86", since = "1.27.0")]
#[allow(clippy::cast_ptr_alignment)]
pub unsafe fn _mm256_store_ps(mem_addr: *const f32, a: __m256) {
pub unsafe fn _mm256_store_ps(mem_addr: *mut f32, a: __m256) {
*(mem_addr as *mut __m256) = a;
}

Expand Down

0 comments on commit f5691cc

Please sign in to comment.