Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
192 changes: 24 additions & 168 deletions fearless_simd/src/generated/avx2.rs
Original file line number Diff line number Diff line change
Expand Up @@ -128,13 +128,7 @@ impl Simd for Avx2 {
}
#[inline(always)]
fn store_array_f32x4(self, a: f32x4<Self>, dest: &mut [f32; 4usize]) -> () {
unsafe {
core::ptr::copy_nonoverlapping(
(&raw const a.val.0) as *const f32,
dest.as_mut_ptr(),
4usize,
);
}
crate::transmute::checked_transmute_store(a.val.0, dest);
}
#[inline(always)]
fn cvt_from_bytes_f32x4(self, a: u8x16<Self>) -> f32x4<Self> {
Expand Down Expand Up @@ -434,13 +428,7 @@ impl Simd for Avx2 {
}
#[inline(always)]
fn store_array_i8x16(self, a: i8x16<Self>, dest: &mut [i8; 16usize]) -> () {
unsafe {
core::ptr::copy_nonoverlapping(
(&raw const a.val.0) as *const i8,
dest.as_mut_ptr(),
16usize,
);
}
crate::transmute::checked_transmute_store(a.val.0, dest);
}
#[inline(always)]
fn cvt_from_bytes_i8x16(self, a: u8x16<Self>) -> i8x16<Self> {
Expand Down Expand Up @@ -664,13 +652,7 @@ impl Simd for Avx2 {
}
#[inline(always)]
fn store_array_u8x16(self, a: u8x16<Self>, dest: &mut [u8; 16usize]) -> () {
unsafe {
core::ptr::copy_nonoverlapping(
(&raw const a.val.0) as *const u8,
dest.as_mut_ptr(),
16usize,
);
}
crate::transmute::checked_transmute_store(a.val.0, dest);
}
#[inline(always)]
fn cvt_from_bytes_u8x16(self, a: u8x16<Self>) -> u8x16<Self> {
Expand Down Expand Up @@ -987,13 +969,7 @@ impl Simd for Avx2 {
}
#[inline(always)]
fn store_array_i16x8(self, a: i16x8<Self>, dest: &mut [i16; 8usize]) -> () {
unsafe {
core::ptr::copy_nonoverlapping(
(&raw const a.val.0) as *const i16,
dest.as_mut_ptr(),
8usize,
);
}
crate::transmute::checked_transmute_store(a.val.0, dest);
}
#[inline(always)]
fn cvt_from_bytes_i16x8(self, a: u8x16<Self>) -> i16x8<Self> {
Expand Down Expand Up @@ -1192,13 +1168,7 @@ impl Simd for Avx2 {
}
#[inline(always)]
fn store_array_u16x8(self, a: u16x8<Self>, dest: &mut [u16; 8usize]) -> () {
unsafe {
core::ptr::copy_nonoverlapping(
(&raw const a.val.0) as *const u16,
dest.as_mut_ptr(),
8usize,
);
}
crate::transmute::checked_transmute_store(a.val.0, dest);
}
#[inline(always)]
fn cvt_from_bytes_u16x8(self, a: u8x16<Self>) -> u16x8<Self> {
Expand Down Expand Up @@ -1490,13 +1460,7 @@ impl Simd for Avx2 {
}
#[inline(always)]
fn store_array_i32x4(self, a: i32x4<Self>, dest: &mut [i32; 4usize]) -> () {
unsafe {
core::ptr::copy_nonoverlapping(
(&raw const a.val.0) as *const i32,
dest.as_mut_ptr(),
4usize,
);
}
crate::transmute::checked_transmute_store(a.val.0, dest);
}
#[inline(always)]
fn cvt_from_bytes_i32x4(self, a: u8x16<Self>) -> i32x4<Self> {
Expand Down Expand Up @@ -1697,13 +1661,7 @@ impl Simd for Avx2 {
}
#[inline(always)]
fn store_array_u32x4(self, a: u32x4<Self>, dest: &mut [u32; 4usize]) -> () {
unsafe {
core::ptr::copy_nonoverlapping(
(&raw const a.val.0) as *const u32,
dest.as_mut_ptr(),
4usize,
);
}
crate::transmute::checked_transmute_store(a.val.0, dest);
}
#[inline(always)]
fn cvt_from_bytes_u32x4(self, a: u8x16<Self>) -> u32x4<Self> {
Expand Down Expand Up @@ -1998,13 +1956,7 @@ impl Simd for Avx2 {
}
#[inline(always)]
fn store_array_f64x2(self, a: f64x2<Self>, dest: &mut [f64; 2usize]) -> () {
unsafe {
core::ptr::copy_nonoverlapping(
(&raw const a.val.0) as *const f64,
dest.as_mut_ptr(),
2usize,
);
}
crate::transmute::checked_transmute_store(a.val.0, dest);
}
#[inline(always)]
fn cvt_from_bytes_f64x2(self, a: u8x16<Self>) -> f64x2<Self> {
Expand Down Expand Up @@ -2315,13 +2267,7 @@ impl Simd for Avx2 {
}
#[inline(always)]
fn store_array_f32x8(self, a: f32x8<Self>, dest: &mut [f32; 8usize]) -> () {
unsafe {
core::ptr::copy_nonoverlapping(
(&raw const a.val.0) as *const f32,
dest.as_mut_ptr(),
8usize,
);
}
crate::transmute::checked_transmute_store(a.val.0, dest);
}
#[inline(always)]
fn cvt_from_bytes_f32x8(self, a: u8x32<Self>) -> f32x8<Self> {
Expand Down Expand Up @@ -2684,13 +2630,7 @@ impl Simd for Avx2 {
}
#[inline(always)]
fn store_array_i8x32(self, a: i8x32<Self>, dest: &mut [i8; 32usize]) -> () {
unsafe {
core::ptr::copy_nonoverlapping(
(&raw const a.val.0) as *const i8,
dest.as_mut_ptr(),
32usize,
);
}
crate::transmute::checked_transmute_store(a.val.0, dest);
}
#[inline(always)]
fn cvt_from_bytes_i8x32(self, a: u8x32<Self>) -> i8x32<Self> {
Expand Down Expand Up @@ -2997,13 +2937,7 @@ impl Simd for Avx2 {
}
#[inline(always)]
fn store_array_u8x32(self, a: u8x32<Self>, dest: &mut [u8; 32usize]) -> () {
unsafe {
core::ptr::copy_nonoverlapping(
(&raw const a.val.0) as *const u8,
dest.as_mut_ptr(),
32usize,
);
}
crate::transmute::checked_transmute_store(a.val.0, dest);
}
#[inline(always)]
fn cvt_from_bytes_u8x32(self, a: u8x32<Self>) -> u8x32<Self> {
Expand Down Expand Up @@ -3425,13 +3359,7 @@ impl Simd for Avx2 {
}
#[inline(always)]
fn store_array_i16x16(self, a: i16x16<Self>, dest: &mut [i16; 16usize]) -> () {
unsafe {
core::ptr::copy_nonoverlapping(
(&raw const a.val.0) as *const i16,
dest.as_mut_ptr(),
16usize,
);
}
crate::transmute::checked_transmute_store(a.val.0, dest);
}
#[inline(always)]
fn cvt_from_bytes_i16x16(self, a: u8x32<Self>) -> i16x16<Self> {
Expand Down Expand Up @@ -3719,13 +3647,7 @@ impl Simd for Avx2 {
}
#[inline(always)]
fn store_array_u16x16(self, a: u16x16<Self>, dest: &mut [u16; 16usize]) -> () {
unsafe {
core::ptr::copy_nonoverlapping(
(&raw const a.val.0) as *const u16,
dest.as_mut_ptr(),
16usize,
);
}
crate::transmute::checked_transmute_store(a.val.0, dest);
}
#[inline(always)]
fn cvt_from_bytes_u16x16(self, a: u8x32<Self>) -> u16x16<Self> {
Expand Down Expand Up @@ -4133,13 +4055,7 @@ impl Simd for Avx2 {
}
#[inline(always)]
fn store_array_i32x8(self, a: i32x8<Self>, dest: &mut [i32; 8usize]) -> () {
unsafe {
core::ptr::copy_nonoverlapping(
(&raw const a.val.0) as *const i32,
dest.as_mut_ptr(),
8usize,
);
}
crate::transmute::checked_transmute_store(a.val.0, dest);
}
#[inline(always)]
fn cvt_from_bytes_i32x8(self, a: u8x32<Self>) -> i32x8<Self> {
Expand Down Expand Up @@ -4401,13 +4317,7 @@ impl Simd for Avx2 {
}
#[inline(always)]
fn store_array_u32x8(self, a: u32x8<Self>, dest: &mut [u32; 8usize]) -> () {
unsafe {
core::ptr::copy_nonoverlapping(
(&raw const a.val.0) as *const u32,
dest.as_mut_ptr(),
8usize,
);
}
crate::transmute::checked_transmute_store(a.val.0, dest);
}
#[inline(always)]
fn cvt_from_bytes_u32x8(self, a: u8x32<Self>) -> u32x8<Self> {
Expand Down Expand Up @@ -4778,13 +4688,7 @@ impl Simd for Avx2 {
}
#[inline(always)]
fn store_array_f64x4(self, a: f64x4<Self>, dest: &mut [f64; 4usize]) -> () {
unsafe {
core::ptr::copy_nonoverlapping(
(&raw const a.val.0) as *const f64,
dest.as_mut_ptr(),
4usize,
);
}
crate::transmute::checked_transmute_store(a.val.0, dest);
}
#[inline(always)]
fn cvt_from_bytes_f64x4(self, a: u8x32<Self>) -> f64x4<Self> {
Expand Down Expand Up @@ -5171,13 +5075,7 @@ impl Simd for Avx2 {
}
#[inline(always)]
fn store_array_f32x16(self, a: f32x16<Self>, dest: &mut [f32; 16usize]) -> () {
unsafe {
core::ptr::copy_nonoverlapping(
(&raw const a.val.0) as *const f32,
dest.as_mut_ptr(),
16usize,
);
}
crate::transmute::checked_transmute_store(a.val.0, dest);
}
#[inline(always)]
fn cvt_from_bytes_f32x16(self, a: u8x64<Self>) -> f32x16<Self> {
Expand Down Expand Up @@ -5594,13 +5492,7 @@ impl Simd for Avx2 {
}
#[inline(always)]
fn store_array_i8x64(self, a: i8x64<Self>, dest: &mut [i8; 64usize]) -> () {
unsafe {
core::ptr::copy_nonoverlapping(
(&raw const a.val.0) as *const i8,
dest.as_mut_ptr(),
64usize,
);
}
crate::transmute::checked_transmute_store(a.val.0, dest);
}
#[inline(always)]
fn cvt_from_bytes_i8x64(self, a: u8x64<Self>) -> i8x64<Self> {
Expand Down Expand Up @@ -5872,13 +5764,7 @@ impl Simd for Avx2 {
}
#[inline(always)]
fn store_array_u8x64(self, a: u8x64<Self>, dest: &mut [u8; 64usize]) -> () {
unsafe {
core::ptr::copy_nonoverlapping(
(&raw const a.val.0) as *const u8,
dest.as_mut_ptr(),
64usize,
);
}
crate::transmute::checked_transmute_store(a.val.0, dest);
}
#[inline(always)]
fn cvt_from_bytes_u8x64(self, a: u8x64<Self>) -> u8x64<Self> {
Expand Down Expand Up @@ -6339,13 +6225,7 @@ impl Simd for Avx2 {
}
#[inline(always)]
fn store_array_i16x32(self, a: i16x32<Self>, dest: &mut [i16; 32usize]) -> () {
unsafe {
core::ptr::copy_nonoverlapping(
(&raw const a.val.0) as *const i16,
dest.as_mut_ptr(),
32usize,
);
}
crate::transmute::checked_transmute_store(a.val.0, dest);
}
#[inline(always)]
fn cvt_from_bytes_i16x32(self, a: u8x64<Self>) -> i16x32<Self> {
Expand Down Expand Up @@ -6626,13 +6506,7 @@ impl Simd for Avx2 {
}
#[inline(always)]
fn store_array_u16x32(self, a: u16x32<Self>, dest: &mut [u16; 32usize]) -> () {
unsafe {
core::ptr::copy_nonoverlapping(
(&raw const a.val.0) as *const u16,
dest.as_mut_ptr(),
32usize,
);
}
crate::transmute::checked_transmute_store(a.val.0, dest);
}
#[inline(always)]
fn cvt_from_bytes_u16x32(self, a: u8x64<Self>) -> u16x32<Self> {
Expand Down Expand Up @@ -7097,13 +6971,7 @@ impl Simd for Avx2 {
}
#[inline(always)]
fn store_array_i32x16(self, a: i32x16<Self>, dest: &mut [i32; 16usize]) -> () {
unsafe {
core::ptr::copy_nonoverlapping(
(&raw const a.val.0) as *const i32,
dest.as_mut_ptr(),
16usize,
);
}
crate::transmute::checked_transmute_store(a.val.0, dest);
}
#[inline(always)]
fn cvt_from_bytes_i32x16(self, a: u8x64<Self>) -> i32x16<Self> {
Expand Down Expand Up @@ -7380,13 +7248,7 @@ impl Simd for Avx2 {
}
#[inline(always)]
fn store_array_u32x16(self, a: u32x16<Self>, dest: &mut [u32; 16usize]) -> () {
unsafe {
core::ptr::copy_nonoverlapping(
(&raw const a.val.0) as *const u32,
dest.as_mut_ptr(),
16usize,
);
}
crate::transmute::checked_transmute_store(a.val.0, dest);
}
#[inline(always)]
fn cvt_from_bytes_u32x16(self, a: u8x64<Self>) -> u32x16<Self> {
Expand Down Expand Up @@ -7824,13 +7686,7 @@ impl Simd for Avx2 {
}
#[inline(always)]
fn store_array_f64x8(self, a: f64x8<Self>, dest: &mut [f64; 8usize]) -> () {
unsafe {
core::ptr::copy_nonoverlapping(
(&raw const a.val.0) as *const f64,
dest.as_mut_ptr(),
8usize,
);
}
crate::transmute::checked_transmute_store(a.val.0, dest);
}
#[inline(always)]
fn cvt_from_bytes_f64x8(self, a: u8x64<Self>) -> f64x8<Self> {
Expand Down
Loading
Loading