From 871d588ec44ec21008df54233dc60615a76e2638 Mon Sep 17 00:00:00 2001 From: Adam Greig Date: Mon, 19 Jul 2021 22:18:29 +0100 Subject: [PATCH] Add 32-bit SIMD types i/u16x2 and i/u8x4. (#145) These types are useful for the "SIMD32" instructions available on ARMv6 (except M-class), ARMv7 (M-class with DSP), and ARMv8. --- crates/core_simd/src/vector/int.rs | 6 ++++++ crates/core_simd/src/vector/uint.rs | 6 ++++++ 2 files changed, 12 insertions(+) diff --git a/crates/core_simd/src/vector/int.rs b/crates/core_simd/src/vector/int.rs index dd7b2225dbd7..75b75d7a15c0 100644 --- a/crates/core_simd/src/vector/int.rs +++ b/crates/core_simd/src/vector/int.rs @@ -136,6 +136,9 @@ pub type isizex4 = SimdIsize<4>; /// Vector of eight `isize` values pub type isizex8 = SimdIsize<8>; +/// Vector of two `i16` values +pub type i16x2 = SimdI16<2>; + /// Vector of four `i16` values pub type i16x4 = SimdI16<4>; @@ -169,6 +172,9 @@ pub type i64x4 = SimdI64<4>; /// Vector of eight `i64` values pub type i64x8 = SimdI64<8>; +/// Vector of four `i8` values +pub type i8x4 = SimdI8<4>; + /// Vector of eight `i8` values pub type i8x8 = SimdI8<8>; diff --git a/crates/core_simd/src/vector/uint.rs b/crates/core_simd/src/vector/uint.rs index db027b0941f2..e7d0fa79c70e 100644 --- a/crates/core_simd/src/vector/uint.rs +++ b/crates/core_simd/src/vector/uint.rs @@ -105,6 +105,9 @@ pub type usizex4 = SimdUsize<4>; /// Vector of eight `usize` values pub type usizex8 = SimdUsize<8>; +/// Vector of two `u16` values +pub type u16x2 = SimdU16<2>; + /// Vector of four `u16` values pub type u16x4 = SimdU16<4>; @@ -138,6 +141,9 @@ pub type u64x4 = SimdU64<4>; /// Vector of eight `u64` values pub type u64x8 = SimdU64<8>; +/// Vector of four `u8` values +pub type u8x4 = SimdU8<4>; + /// Vector of eight `u8` values pub type u8x8 = SimdU8<8>;