@@ -1776,288 +1776,288 @@ mod tests {
17761776
17771777 #[ simd_test( enable = "neon" ) ]
17781778 unsafe fn test_vand_s8 ( ) {
1779- let a = i8x8:: new ( 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 ) ;
1780- let b = i8x8:: new ( 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 ) ;
1781- let e = i8x8:: new ( 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 ) ;
1779+ let a = i8x8:: new ( 0xF0 , 0xF1 , 0xF2 , 0xF3 , 0xF4 , 0xF5 , 0xF6 , 0xF7 ) ;
1780+ let b = i8x8:: new ( 0x0F , 0x1F , 0x2F , 0x3F , 0x4F , 0x5F , 0x6F , 0x7F ) ;
1781+ let e = i8x8:: new ( 0x00 , 0x11 , 0x22 , 0x33 , 0x44 , 0x55 , 0x66 , 0x77 ) ;
17821782 let r: i8x8 = transmute ( vand_s8 ( transmute ( a) , transmute ( b) ) ) ;
17831783 assert_eq ! ( r, e) ;
17841784 }
17851785
17861786 #[ simd_test( enable = "neon" ) ]
17871787 unsafe fn test_vandq_s8 ( ) {
1788- let a = i8x16:: new ( 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 ) ;
1789- let b = i8x16:: new ( 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 ) ;
1790- let e = i8x16:: new ( 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 ) ;
1788+ let a = i8x16:: new ( 0xF0 , 0xF1 , 0xF2 , 0xF3 , 0xF4 , 0xF5 , 0xF6 , 0xF7 , 0xF8 , 0xF9 , 0xFA , 0xFB , 0xFC , 0xFD , 0xFE , 0xFF ) ;
1789+ let b = i8x16:: new ( 0x0F , 0x1F , 0x2F , 0x3F , 0x4F , 0x5F , 0x6F , 0x7F , 0x8F , 0x9F , 0xAF , 0xBF , 0xCF , 0xDF , 0xEF , 0xFF ) ;
1790+ let e = i8x16:: new ( 0x00 , 0x11 , 0x22 , 0x33 , 0x44 , 0x55 , 0x66 , 0x77 , 0x88 , 0x99 , 0xAA , 0xBB , 0xCC , 0xDD , 0xEE , 0xFF ) ;
17911791 let r: i8x16 = transmute ( vandq_s8 ( transmute ( a) , transmute ( b) ) ) ;
17921792 assert_eq ! ( r, e) ;
17931793 }
17941794
17951795 #[ simd_test( enable = "neon" ) ]
17961796 unsafe fn test_vand_s16 ( ) {
1797- let a = i16x4:: new ( 20 , 20 , 20 , 20 ) ;
1798- let b = i16x4:: new ( 21 , 21 , 21 , 21 ) ;
1799- let e = i16x4:: new ( 20 , 20 , 20 , 20 ) ;
1797+ let a = i16x4:: new ( 0xF0F1 , 0xF2F3 , 0xF4F5 , 0xF6F7 ) ;
1798+ let b = i16x4:: new ( 0x0F1F , 0x2F3F , 0x4F5F , 0x6F7F ) ;
1799+ let e = i16x4:: new ( 0x0011 , 0x2233 , 0x4455 , 0x6677 ) ;
18001800 let r: i16x4 = transmute ( vand_s16 ( transmute ( a) , transmute ( b) ) ) ;
18011801 assert_eq ! ( r, e) ;
18021802 }
18031803
18041804 #[ simd_test( enable = "neon" ) ]
18051805 unsafe fn test_vandq_s16 ( ) {
1806- let a = i16x8:: new ( 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 ) ;
1807- let b = i16x8:: new ( 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 ) ;
1808- let e = i16x8:: new ( 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 ) ;
1806+ let a = i16x8:: new ( 0xF0F1 , 0xF2F3 , 0xF4F5 , 0xF6F7 , 0xF8F9 , 0xFAFB , 0xFCFD , 0xFEFF ) ;
1807+ let b = i16x8:: new ( 0x0F1F , 0x2F3F , 0x4F5F , 0x6F7F , 0x8F9F , 0xAFBF , 0xCFDF , 0xEFFF ) ;
1808+ let e = i16x8:: new ( 0x0011 , 0x2233 , 0x4455 , 0x6677 , 0x8899 , 0xAABB , 0xCCDD , 0xEEFF ) ;
18091809 let r: i16x8 = transmute ( vandq_s16 ( transmute ( a) , transmute ( b) ) ) ;
18101810 assert_eq ! ( r, e) ;
18111811 }
18121812
18131813 #[ simd_test( enable = "neon" ) ]
18141814 unsafe fn test_vand_s32 ( ) {
1815- let a = i32x2:: new ( 20 , 20 ) ;
1816- let b = i32x2:: new ( 21 , 21 ) ;
1817- let e = i32x2:: new ( 20 , 20 ) ;
1815+ let a = i32x2:: new ( 0xF0F1F2F3 , 0xF4F5F6F7 ) ;
1816+ let b = i32x2:: new ( 0x0F1F2F3F , 0x4F5F6F7F ) ;
1817+ let e = i32x2:: new ( 0x00112233 , 0x44556677 ) ;
18181818 let r: i32x2 = transmute ( vand_s32 ( transmute ( a) , transmute ( b) ) ) ;
18191819 assert_eq ! ( r, e) ;
18201820 }
18211821
18221822 #[ simd_test( enable = "neon" ) ]
18231823 unsafe fn test_vandq_s32 ( ) {
1824- let a = i32x4:: new ( 20 , 20 , 20 , 20 ) ;
1825- let b = i32x4:: new ( 21 , 21 , 21 , 21 ) ;
1826- let e = i32x4:: new ( 20 , 20 , 20 , 20 ) ;
1824+ let a = i32x4:: new ( 0xF0F1F2F3 , 0xF4F5F6F7 , 0xF8F9FAFB , 0xFCFDFEFF ) ;
1825+ let b = i32x4:: new ( 0x0F1F2F3F , 0x4F5F6F7F , 0x8F9FAFBF , 0xCFDFEFFF ) ;
1826+ let e = i32x4:: new ( 0x00112233 , 0x44556677 , 0x8899AABB , 0xCCDDEEFF ) ;
18271827 let r: i32x4 = transmute ( vandq_s32 ( transmute ( a) , transmute ( b) ) ) ;
18281828 assert_eq ! ( r, e) ;
18291829 }
18301830
18311831 #[ simd_test( enable = "neon" ) ]
18321832 unsafe fn test_vand_s64 ( ) {
1833- let a = i64x1:: new ( 20 ) ;
1834- let b = i64x1:: new ( 21 ) ;
1835- let e = i64x1:: new ( 20 ) ;
1833+ let a = i64x1:: new ( 0xF0F1F2F3F4F5F6F7 ) ;
1834+ let b = i64x1:: new ( 0x0F1F2F3F4F5F6F7F ) ;
1835+ let e = i64x1:: new ( 0x0011223344556677 ) ;
18361836 let r: i64x1 = transmute ( vand_s64 ( transmute ( a) , transmute ( b) ) ) ;
18371837 assert_eq ! ( r, e) ;
18381838 }
18391839
18401840 #[ simd_test( enable = "neon" ) ]
18411841 unsafe fn test_vandq_s64 ( ) {
1842- let a = i64x2:: new ( 20 , 20 ) ;
1843- let b = i64x2:: new ( 21 , 21 ) ;
1844- let e = i64x2:: new ( 20 , 20 ) ;
1842+ let a = i64x2:: new ( 0xF0F1F2F3F4F5F6F7 , 0xF8F9FAFBFCFDFEFF ) ;
1843+ let b = i64x2:: new ( 0x0F1F2F3F4F5F6F7F , 0x8F9FAFBFCFDFEFFF ) ;
1844+ let e = i64x2:: new ( 0x0011223344556677 , 0x8899AABBCCDDEEFF ) ;
18451845 let r: i64x2 = transmute ( vandq_s64 ( transmute ( a) , transmute ( b) ) ) ;
18461846 assert_eq ! ( r, e) ;
18471847 }
18481848
18491849 #[ simd_test( enable = "neon" ) ]
18501850 unsafe fn test_vand_u8 ( ) {
1851- let a = u8x8:: new ( 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 ) ;
1852- let b = u8x8:: new ( 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 ) ;
1853- let e = u8x8:: new ( 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 ) ;
1851+ let a = u8x8:: new ( 0xF0 , 0xF1 , 0xF2 , 0xF3 , 0xF4 , 0xF5 , 0xF6 , 0xF7 ) ;
1852+ let b = u8x8:: new ( 0x0F , 0x1F , 0x2F , 0x3F , 0x4F , 0x5F , 0x6F , 0x7F ) ;
1853+ let e = u8x8:: new ( 0x00 , 0x11 , 0x22 , 0x33 , 0x44 , 0x55 , 0x66 , 0x77 ) ;
18541854 let r: u8x8 = transmute ( vand_u8 ( transmute ( a) , transmute ( b) ) ) ;
18551855 assert_eq ! ( r, e) ;
18561856 }
18571857
18581858 #[ simd_test( enable = "neon" ) ]
18591859 unsafe fn test_vandq_u8 ( ) {
1860- let a = u8x16:: new ( 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 ) ;
1861- let b = u8x16:: new ( 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 ) ;
1862- let e = u8x16:: new ( 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 ) ;
1860+ let a = u8x16:: new ( 0xF0 , 0xF1 , 0xF2 , 0xF3 , 0xF4 , 0xF5 , 0xF6 , 0xF7 , 0xF8 , 0xF9 , 0xFA , 0xFB , 0xFC , 0xFD , 0xFE , 0xFF ) ;
1861+ let b = u8x16:: new ( 0x0F , 0x1F , 0x2F , 0x3F , 0x4F , 0x5F , 0x6F , 0x7F , 0x8F , 0x9F , 0xAF , 0xBF , 0xCF , 0xDF , 0xEF , 0xFF ) ;
1862+ let e = u8x16:: new ( 0x00 , 0x11 , 0x22 , 0x33 , 0x44 , 0x55 , 0x66 , 0x77 , 0x88 , 0x99 , 0xAA , 0xBB , 0xCC , 0xDD , 0xEE , 0xFF ) ;
18631863 let r: u8x16 = transmute ( vandq_u8 ( transmute ( a) , transmute ( b) ) ) ;
18641864 assert_eq ! ( r, e) ;
18651865 }
18661866
18671867 #[ simd_test( enable = "neon" ) ]
18681868 unsafe fn test_vand_u16 ( ) {
1869- let a = u16x4:: new ( 20 , 20 , 20 , 20 ) ;
1870- let b = u16x4:: new ( 21 , 21 , 21 , 21 ) ;
1871- let e = u16x4:: new ( 20 , 20 , 20 , 20 ) ;
1869+ let a = u16x4:: new ( 0xF0F1 , 0xF2F3 , 0xF4F5 , 0xF6F7 ) ;
1870+ let b = u16x4:: new ( 0x0F1F , 0x2FF , 0x4F5F , 0x6F7F ) ;
1871+ let e = u16x4:: new ( 0x0011 , 0x2233 , 0x4455 , 0x667 ) ;
18721872 let r: u16x4 = transmute ( vand_u16 ( transmute ( a) , transmute ( b) ) ) ;
18731873 assert_eq ! ( r, e) ;
18741874 }
18751875
18761876 #[ simd_test( enable = "neon" ) ]
18771877 unsafe fn test_vandq_u16 ( ) {
1878- let a = u16x8:: new ( 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 ) ;
1879- let b = u16x8:: new ( 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 ) ;
1880- let e = u16x8:: new ( 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 ) ;
1878+ let a = u16x8:: new ( 0xF0F1 , 0xF2F3 , 0xF4F5 , 0xF6F7 , 0xF8F9 , 0xFAFB , 0xFCFD , 0xFEFF ) ;
1879+ let b = u16x8:: new ( 0x0F1F , 0x2F3F , 0x4F5F , 0x6F7F , 0x8F9F , 0xAFBF , 0xCFDF , 0xEFFF ) ;
1880+ let e = u16x8:: new ( 0x0011 , 0x2233 , 0x4455 , 0x6677 , 0x8899 , 0xAABB , 0xCCDD , 0xEEFF ) ;
18811881 let r: u16x8 = transmute ( vandq_u16 ( transmute ( a) , transmute ( b) ) ) ;
18821882 assert_eq ! ( r, e) ;
18831883 }
18841884
18851885 #[ simd_test( enable = "neon" ) ]
18861886 unsafe fn test_vand_u32 ( ) {
1887- let a = u32x2:: new ( 20 , 20 ) ;
1888- let b = u32x2:: new ( 21 , 21 ) ;
1889- let e = u32x2:: new ( 20 , 20 ) ;
1887+ let a = u32x2:: new ( 0xF0F1F2F3 , 0xF4F5F6F7 ) ;
1888+ let b = u32x2:: new ( 0x0F1F2F3F , 0x4F5F6F7F ) ;
1889+ let e = u32x2:: new ( 0x00112233 , 0x44556677 ) ;
18901890 let r: u32x2 = transmute ( vand_u32 ( transmute ( a) , transmute ( b) ) ) ;
18911891 assert_eq ! ( r, e) ;
18921892 }
18931893
18941894 #[ simd_test( enable = "neon" ) ]
18951895 unsafe fn test_vandq_u32 ( ) {
1896- let a = u32x4:: new ( 20 , 20 , 20 , 20 ) ;
1897- let b = u32x4:: new ( 21 , 21 , 21 , 21 ) ;
1898- let e = u32x4:: new ( 20 , 20 , 20 , 20 ) ;
1896+ let a = u32x4:: new ( 0xF0F1F2F3 , 0xF4F5F6F7 , 0xF8F9FAFB , 0xFCFDFEFF ) ;
1897+ let b = u32x4:: new ( 0x0F1F2F3F , 0x4F5F6F7F , 0x8F9FAFBF , 0xCFDFEFFF ) ;
1898+ let e = u32x4:: new ( 0x00112233 , 0x44556677 , 0x8899AABB , 0xCCDDEEFF ) ;
18991899 let r: u32x4 = transmute ( vandq_u32 ( transmute ( a) , transmute ( b) ) ) ;
19001900 assert_eq ! ( r, e) ;
19011901 }
19021902
19031903 #[ simd_test( enable = "neon" ) ]
19041904 unsafe fn test_vand_u64 ( ) {
1905- let a = u64x1 :: new ( 20 ) ;
1906- let b = u64x1 :: new ( 21 ) ;
1907- let e = u64x1 :: new ( 20 ) ;
1905+ let a = i64x1 :: new ( 0xF0F1F2F3F4F5F6F7 ) ;
1906+ let b = i64x1 :: new ( 0x0F1F2F3F4F5F6F7F ) ;
1907+ let e = i64x1 :: new ( 0x0011223344556677 ) ;
19081908 let r: u64x1 = transmute ( vand_u64 ( transmute ( a) , transmute ( b) ) ) ;
19091909 assert_eq ! ( r, e) ;
19101910 }
19111911
19121912 #[ simd_test( enable = "neon" ) ]
19131913 unsafe fn test_vandq_s64 ( ) {
1914- let a = u64x2 :: new ( 20 , 20 ) ;
1915- let b = u64x2 :: new ( 21 , 21 ) ;
1916- let e = u64x2 :: new ( 20 , 20 ) ;
1914+ let a = i64x2 :: new ( 0xF0F1F2F3F4F5F6F7 , 0xF8F9FAFBFCFDFEFF ) ;
1915+ let b = i64x2 :: new ( 0x0F1F2F3F4F5F6F7F , 0x8F9FAFBFCFDFEFFF ) ;
1916+ let e = i64x2 :: new ( 0x0011223344556677 , 0x8899AABBCCDDEEFF ) ;
19171917 let r: u64x2 = transmute ( vandq_u64 ( transmute ( a) , transmute ( b) ) ) ;
19181918 assert_eq ! ( r, e) ;
19191919 }
19201920
19211921 #[ simd_test( enable = "neon" ) ]
19221922 unsafe fn test_vorr_s8 ( ) {
1923- let a = i8x8:: new ( 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 ) ;
1924- let b = i8x8:: new ( 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 ) ;
1925- let e = i8x8:: new ( 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 ) ;
1923+ let a = i8x8:: new ( 0x00 , 0x01 , 0x02 , 0x03 , 0x04 , 0x05 , 0x06 , 0x07 ) ;
1924+ let b = i8x8:: new ( 0x00 , 0x10 , 0x20 , 0x30 , 0x40 , 0x50 , 0x60 , 0x70 ) ;
1925+ let e = i8x8:: new ( 0x00 , 0x11 , 0x22 , 0x33 , 0x44 , 0x55 , 0x66 , 0x77 ) ;
19261926 let r: i8x8 = transmute ( vorr_s8 ( transmute ( a) , transmute ( b) ) ) ;
19271927 assert_eq ! ( r, e) ;
19281928 }
19291929
19301930 #[ simd_test( enable = "neon" ) ]
19311931 unsafe fn test_vorrq_s8 ( ) {
1932- let a = i8x16:: new ( 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 ) ;
1933- let b = i8x16:: new ( 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 ) ;
1934- let e = i8x16:: new ( 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 ) ;
1932+ let a = i8x16:: new ( 0x00 , 0x01 , 0x02 , 0x03 , 0x04 , 0x05 , 0x06 , 0x07 , 0x08 , 0x09 , 0x0A , 0x0B , 0x0C , 0x0D , 0x0E , 0x0F ) ;
1933+ let b = i8x16:: new ( 0x00 , 0x10 , 0x20 , 0x30 , 0x40 , 0x50 , 0x60 , 0x70 , 0x80 , 0x90 , 0xA0 , 0xB0 , 0xC0 , 0xD0 , 0xE0 , 0xF0 ) ;
1934+ let e = i8x16:: new ( 0x00 , 0x11 , 0x22 , 0x33 , 0x44 , 0x55 , 0x66 , 0x77 , 0x88 , 0x99 , 0xAA , 0xBB , 0xCC , 0xDD , 0xEE , 0xFF ) ;
19351935 let r: i8x16 = transmute ( vorrq_s8 ( transmute ( a) , transmute ( b) ) ) ;
19361936 assert_eq ! ( r, e) ;
19371937 }
19381938
19391939 #[ simd_test( enable = "neon" ) ]
19401940 unsafe fn test_vorr_s16 ( ) {
1941- let a = i16x4:: new ( 20 , 20 , 20 , 20 ) ;
1942- let b = i16x4:: new ( 21 , 21 , 21 , 21 ) ;
1943- let e = i16x4:: new ( 21 , 21 , 21 , 21 ) ;
1941+ let a = i16x4:: new ( 0x0001 , 0x0203 , 0x0405 , 0x0607 ) ;
1942+ let b = i16x4:: new ( 0x0010 , 0x2030 , 0x4050 , 0x6070 ) ;
1943+ let e = i16x4:: new ( 0x0011 , 0x2233 , 0x4455 , 0x6677 ) ;
19441944 let r: i16x4 = transmute ( vorr_s16 ( transmute ( a) , transmute ( b) ) ) ;
19451945 assert_eq ! ( r, e) ;
19461946 }
19471947
19481948 #[ simd_test( enable = "neon" ) ]
19491949 unsafe fn test_vorrq_s16 ( ) {
1950- let a = i16x8:: new ( 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 ) ;
1951- let b = i16x8:: new ( 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 ) ;
1952- let e = i16x8:: new ( 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 ) ;
1950+ let a = i16x8:: new ( 0x0001 , 0x0203 , 0x0405 , 0x0607 , 0x0809 , 0x0A0B , 0x0C0D , 0x0E0F ) ;
1951+ let b = i16x8:: new ( 0x0010 , 0x2030 , 0x4050 , 0x6070 , 0x8090 , 0xA0B0 , 0xC0D0 , 0xE0F0 ) ;
1952+ let e = i16x8:: new ( 0x0011 , 0x2233 , 0x4455 , 0x6677 , 0x8899 , 0xAABB , 0xCCDD , 0xEEFF ) ;
19531953 let r: i16x8 = transmute ( vorrq_s16 ( transmute ( a) , transmute ( b) ) ) ;
19541954 assert_eq ! ( r, e) ;
19551955 }
19561956
19571957 #[ simd_test( enable = "neon" ) ]
19581958 unsafe fn test_vorr_s32 ( ) {
1959- let a = i32x2:: new ( 20 , 20 ) ;
1960- let b = i32x2:: new ( 21 , 21 ) ;
1961- let e = i32x2:: new ( 21 , 21 ) ;
1959+ let a = i32x2:: new ( 0x00010203 , 0x04050607 ) ;
1960+ let b = i32x2:: new ( 0x00102030 , 0x40506070 ) ;
1961+ let e = i32x2:: new ( 0x00112233 , 0x44556677 ) ;
19621962 let r: i32x2 = transmute ( vorr_s32 ( transmute ( a) , transmute ( b) ) ) ;
19631963 assert_eq ! ( r, e) ;
19641964 }
19651965
19661966 #[ simd_test( enable = "neon" ) ]
19671967 unsafe fn test_vorrq_s32 ( ) {
1968- let a = i32x4:: new ( 20 , 20 , 20 , 20 ) ;
1969- let b = i32x4:: new ( 21 , 21 , 21 , 21 ) ;
1970- let e = i32x4:: new ( 21 , 21 , 21 , 21 ) ;
1968+ let a = i32x4:: new ( 0x00010203 , 0x04050607 , 0x08090A0B , 0x0C0D0E0F ) ;
1969+ let b = i32x4:: new ( 0x00102030 , 0x40506070 , 0x8090A0B0 , 0xC0D0E0F0 ) ;
1970+ let e = i32x4:: new ( 0x00112233 , 0x44556677 , 0x8899AABB , 0xCCDDEEFF ) ;
19711971 let r: i32x4 = transmute ( vorrq_s32 ( transmute ( a) , transmute ( b) ) ) ;
19721972 assert_eq ! ( r, e) ;
19731973 }
19741974
19751975 #[ simd_test( enable = "neon" ) ]
19761976 unsafe fn test_vorr_s64 ( ) {
1977- let a = i64x1:: new ( 20 ) ;
1978- let b = i64x1:: new ( 21 ) ;
1979- let e = i64x1:: new ( 21 ) ;
1977+ let a = i64x1:: new ( 0x0001020304050607 ) ;
1978+ let b = i64x1:: new ( 0x0010203040506070 ) ;
1979+ let e = i64x1:: new ( 0x0011223344556677 ) ;
19801980 let r: i64x1 = transmute ( vorr_s64 ( transmute ( a) , transmute ( b) ) ) ;
19811981 assert_eq ! ( r, e) ;
19821982 }
19831983
19841984 #[ simd_test( enable = "neon" ) ]
19851985 unsafe fn test_vorrq_s64 ( ) {
1986- let a = i64x2:: new ( 20 , 20 ) ;
1987- let b = i64x2:: new ( 21 , 21 ) ;
1988- let e = i64x2:: new ( 21 , 21 ) ;
1986+ let a = i64x2:: new ( 0x0001020304050607 , 0x08090A0B0C0D0E0F ) ;
1987+ let b = i64x2:: new ( 0x0010203040506070 , 0x8090A0B0C0D0E0F0 ) ;
1988+ let e = i64x2:: new ( 0x0011223344556677 , 0x8899AABBCCDDEEFF ) ;
19891989 let r: i64x2 = transmute ( vorrq_s64 ( transmute ( a) , transmute ( b) ) ) ;
19901990 assert_eq ! ( r, e) ;
19911991 }
19921992
19931993 #[ simd_test( enable = "neon" ) ]
19941994 unsafe fn test_vorr_u8 ( ) {
1995- let a = u8x8:: new ( 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 ) ;
1996- let b = u8x8:: new ( 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 ) ;
1997- let e = u8x8:: new ( 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 ) ;
1995+ let a = u8x8:: new ( 0x00 , 0x01 , 0x02 , 0x03 , 0x04 , 0x05 , 0x06 , 0x07 ) ;
1996+ let b = u8x8:: new ( 0x00 , 0x10 , 0x20 , 0x30 , 0x40 , 0x50 , 0x60 , 0x70 ) ;
1997+ let e = u8x8:: new ( 0x00 , 0x11 , 0x22 , 0x33 , 0x44 , 0x55 , 0x66 , 0x77 ) ;
19981998 let r: u8x8 = transmute ( vorr_u8 ( transmute ( a) , transmute ( b) ) ) ;
19991999 assert_eq ! ( r, e) ;
20002000 }
20012001
20022002 #[ simd_test( enable = "neon" ) ]
20032003 unsafe fn test_vorrq_u8 ( ) {
2004- let a = u8x16:: new ( 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 ) ;
2005- let b = u8x16:: new ( 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 ) ;
2006- let e = u8x16:: new ( 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 ) ;
2004+ let a = u8x16:: new ( 0x00 , 0x01 , 0x02 , 0x03 , 0x04 , 0x05 , 0x06 , 0x07 , 0x08 , 0x09 , 0x0A , 0x0B , 0x0C , 0x0D , 0x0E , 0x0F ) ;
2005+ let b = u8x16:: new ( 0x00 , 0x10 , 0x20 , 0x30 , 0x40 , 0x50 , 0x60 , 0x70 , 0x80 , 0x90 , 0xA0 , 0xB0 , 0xC0 , 0xD0 , 0xE0 , 0xF0 ) ;
2006+ let e = u8x16:: new ( 0x00 , 0x11 , 0x22 , 0x33 , 0x44 , 0x55 , 0x66 , 0x77 , 0x88 , 0x99 , 0xAA , 0xBB , 0xCC , 0xDD , 0xEE , 0xFF ) ;
20072007 let r: u8x16 = transmute ( vorrq_u8 ( transmute ( a) , transmute ( b) ) ) ;
20082008 assert_eq ! ( r, e) ;
20092009 }
20102010
20112011 #[ simd_test( enable = "neon" ) ]
20122012 unsafe fn test_vorr_u16 ( ) {
2013- let a = u16x4:: new ( 20 , 20 , 20 , 20 ) ;
2014- let b = u16x4:: new ( 21 , 21 , 21 , 21 ) ;
2015- let e = u16x4:: new ( 21 , 21 , 21 , 21 ) ;
2013+ let a = u16x4:: new ( 0x0001 , 0x0203 , 0x0405 , 0x0607 ) ;
2014+ let b = u16x4:: new ( 0x0010 , 0x2030 , 0x4050 , 0x6070 ) ;
2015+ let e = u16x4:: new ( 0x0011 , 0x2233 , 0x4455 , 0x6677 ) ;
20162016 let r: u16x4 = transmute ( vorr_u16 ( transmute ( a) , transmute ( b) ) ) ;
20172017 assert_eq ! ( r, e) ;
20182018 }
20192019
20202020 #[ simd_test( enable = "neon" ) ]
20212021 unsafe fn test_vorrq_u16 ( ) {
2022- let a = u16x8:: new ( 20 , 20 , 20 , 20 , 20 , 20 , 20 , 20 ) ;
2023- let b = u16x8:: new ( 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 ) ;
2024- let e = u16x8:: new ( 21 , 21 , 21 , 21 , 21 , 21 , 21 , 21 ) ;
2022+ let a = u16x8:: new ( 0x0001 , 0x0203 , 0x0405 , 0x0607 , 0x0809 , 0x0A0B , 0x0C0D , 0x0E0F ) ;
2023+ let b = u16x8:: new ( 0x0010 , 0x2030 , 0x4050 , 0x6070 , 0x8090 , 0xA0B0 , 0xC0D0 , 0xE0F0 ) ;
2024+ let e = u16x8:: new ( 0x0011 , 0x2233 , 0x4455 , 0x6677 , 0x8899 , 0xAABB , 0xCCDD , 0xEEFF ) ;
20252025 let r: u16x8 = transmute ( vorrq_u16 ( transmute ( a) , transmute ( b) ) ) ;
20262026 assert_eq ! ( r, e) ;
20272027 }
20282028
20292029 #[ simd_test( enable = "neon" ) ]
20302030 unsafe fn test_vorr_u32 ( ) {
2031- let a = u32x2:: new ( 20 , 20 ) ;
2032- let b = u32x2:: new ( 21 , 21 ) ;
2033- let e = u32x2:: new ( 21 , 21 ) ;
2031+ let a = u32x2:: new ( 0x00010203 , 0x04050607 ) ;
2032+ let b = u32x2:: new ( 0x00102030 , 0x40506070 ) ;
2033+ let e = u32x2:: new ( 0x00112233 , 0x44556677 ) ;
20342034 let r: u32x2 = transmute ( vorr_u32 ( transmute ( a) , transmute ( b) ) ) ;
20352035 assert_eq ! ( r, e) ;
20362036 }
20372037
20382038 #[ simd_test( enable = "neon" ) ]
20392039 unsafe fn test_vorrq_u32 ( ) {
2040- let a = u32x4:: new ( 20 , 20 , 20 , 20 ) ;
2041- let b = u32x4:: new ( 21 , 21 , 21 , 21 ) ;
2042- let e = u32x4:: new ( 21 , 21 , 21 , 21 ) ;
2040+ let a = u32x4:: new ( 0x00010203 , 0x04050607 , 0x08090A0B , 0x0C0D0E0F ) ;
2041+ let b = u32x4:: new ( 0x00102030 , 0x40506070 , 0x8090A0B0 , 0xC0D0E0F0 ) ;
2042+ let e = u32x4:: new ( 0x00112233 , 0x44556677 , 0x8899AABB , 0xCCDDEEFF ) ;
20432043 let r: u32x4 = transmute ( vorrq_u32 ( transmute ( a) , transmute ( b) ) ) ;
20442044 assert_eq ! ( r, e) ;
20452045 }
20462046
20472047 #[ simd_test( enable = "neon" ) ]
20482048 unsafe fn test_vorr_u64 ( ) {
2049- let a = u64x1:: new ( 20 ) ;
2050- let b = u64x1:: new ( 21 ) ;
2051- let e = u64x1:: new ( 21 ) ;
2049+ let a = u64x1:: new ( 0x0001020304050607 ) ;
2050+ let b = u64x1:: new ( 0x0010203040506070 ) ;
2051+ let e = u64x1:: new ( 0x0011223344556677 ) ;
20522052 let r: u64x1 = transmute ( vorr_u64 ( transmute ( a) , transmute ( b) ) ) ;
20532053 assert_eq ! ( r, e) ;
20542054 }
20552055
20562056 #[ simd_test( enable = "neon" ) ]
2057- unsafe fn test_vorrq_s64 ( ) {
2058- let a = u64x2:: new ( 20 , 20 ) ;
2059- let b = u64x2:: new ( 21 , 21 ) ;
2060- let e = u64x2:: new ( 21 , 21 ) ;
2057+ unsafe fn test_vorrq_u64 ( ) {
2058+ let a = u64x2:: new ( 0x0001020304050607 , 0x08090A0B0C0D0E0F ) ;
2059+ let b = u64x2:: new ( 0x0010203040506070 , 0x8090A0B0C0D0E0F0 ) ;
2060+ let e = u64x2:: new ( 0x0011223344556677 , 0x8899AABBCCDDEEFF ) ;
20612061 let r: u64x2 = transmute ( vorrq_u64 ( transmute ( a) , transmute ( b) ) ) ;
20622062 assert_eq ! ( r, e) ;
20632063 }
0 commit comments