1616 #[ inline]
1717 pub fn swizzle_dyn ( self , idxs : Simd < u8 , N > ) -> Self {
1818 #![ allow( unused_imports, unused_unsafe) ]
19- #[ cfg( target_arch = "aarch64" ) ]
19+ #[ cfg( all ( target_arch = "aarch64" , target_endian = "little" ) ) ]
2020 use core:: arch:: aarch64:: { uint8x8_t, vqtbl1q_u8, vtbl1_u8} ;
21- #[ cfg( all( target_arch = "arm" , target_feature = "v7" ) ) ]
21+ #[ cfg( all( target_arch = "arm" , target_feature = "v7" , target_endian = "little" ) ) ]
2222 use core:: arch:: arm:: { uint8x8_t, vtbl1_u8} ;
2323 #[ cfg( target_arch = "wasm32" ) ]
2424 use core:: arch:: wasm32 as wasm;
@@ -29,13 +29,17 @@ where
2929 // SAFETY: Intrinsics covered by cfg
3030 unsafe {
3131 match N {
32- #[ cfg( target_feature = "neon" ) ]
32+ #[ cfg( all ( target_feature = "neon" , target_endian = "little" ) ) ]
3333 8 => transize ( vtbl1_u8, self , idxs) ,
3434 #[ cfg( target_feature = "ssse3" ) ]
3535 16 => transize ( x86:: _mm_shuffle_epi8, self , idxs) ,
3636 #[ cfg( target_feature = "simd128" ) ]
3737 16 => transize ( wasm:: i8x16_swizzle, self , idxs) ,
38- #[ cfg( all( target_arch = "aarch64" , target_feature = "neon" ) ) ]
38+ #[ cfg( all(
39+ target_arch = "aarch64" ,
40+ target_feature = "neon" ,
41+ target_endian = "little"
42+ ) ) ]
3943 16 => transize ( vqtbl1q_u8, self , idxs) ,
4044 #[ cfg( all( target_feature = "avx2" , not( target_feature = "avx512vbmi" ) ) ) ]
4145 32 => transize_raw ( avx2_pshufb, self , idxs) ,
0 commit comments