Skip to content

Commit 2357f08

Browse files
committed
Come cleanup
1 parent 9cad541 commit 2357f08

File tree

1 file changed

+4
-13
lines changed

1 file changed

+4
-13
lines changed

crates/core_arch/src/arm/neon.rs

+4-13
Original file line numberDiff line numberDiff line change
@@ -1578,7 +1578,7 @@ pub unsafe fn vextq_s8(a: int8x16_t, b: int8x16_t, n: u32) -> int8x16_t {
15781578
#[target_feature(enable = "neon")]
15791579
#[cfg_attr(target_arch = "arm", target_feature(enable = "v7"))]
15801580
#[cfg_attr(test, assert_instr(ushr))]
1581-
pub unsafe fn vshrq_n_u8(a: uint8x16_t, imm8: i32) -> uint8x16_t {
1581+
pub unsafe fn vshrq_n_u8(a: uint8x16_t, imm8: u32) -> uint8x16_t {
15821582
macro_rules! call {
15831583
($imm8:expr) => {
15841584
if $imm8 == 0 {
@@ -1613,8 +1613,8 @@ pub unsafe fn vshrq_n_u8(a: uint8x16_t, imm8: i32) -> uint8x16_t {
16131613
#[target_feature(enable = "neon")]
16141614
#[cfg_attr(target_arch = "arm", target_feature(enable = "v7"))]
16151615
#[cfg_attr(test, assert_instr(ushl))]
1616-
pub unsafe fn vshlq_n_u8(a: uint8x16_t, n: i32) -> uint8x16_t {
1617-
if n < 0 || n > 7 {
1616+
pub unsafe fn vshlq_n_u8(a: uint8x16_t, n: u32) -> uint8x16_t {
1617+
if n > 7 {
16181618
unreachable_unchecked();
16191619
};
16201620
uint8x16_t(
@@ -1686,7 +1686,7 @@ mod tests {
16861686
let b = i8x16::new(
16871687
42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42,
16881688
);
1689-
let e = i8x16::new(1, 2, 3, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42);
1689+
let e = i8x16::new(1, 2, 3, 4, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42);
16901690
let r: i8x16 = transmute(vextq_s8(transmute(a), transmute(b), 3));
16911691
assert_eq!(r, e);
16921692
}
@@ -1707,15 +1707,6 @@ mod tests {
17071707
assert_eq!(r, e);
17081708
}
17091709

1710-
#[simd_test(enable = "neon")]
1711-
unsafe fn test_vst1q_u8() {
1712-
let a = u8x16::new(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16);
1713-
let e = a;
1714-
let mut r = u8x16::new(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
1715-
vst1q_u8(transmute(&mut r), transmute(a));
1716-
assert_eq!(r, e);
1717-
}
1718-
17191710
#[simd_test(enable = "neon")]
17201711
unsafe fn test_vreinterpret_u64_u32() {
17211712
let v: i8 = 42;

0 commit comments

Comments
 (0)