AArch64/ARM64: run AArch64 NEON MC tests through ARM64 too.
[oota-llvm.git] / test / MC / AArch64 / neon-saturating-rounding-shift.s
1 // RUN: llvm-mc -triple aarch64-none-linux-gnu -mattr=+neon -show-encoding < %s | FileCheck %s
2 // RUN: llvm-mc -triple arm64-none-linux-gnu -mattr=+neon -show-encoding < %s | FileCheck %s
3
4 // Check that the assembler can handle the documented syntax for AArch64
5
6
7 //------------------------------------------------------------------------------
8 // Vector Integer Saturating Rounding Shift Lef (Signed)
9 //------------------------------------------------------------------------------
10          sqrshl v0.8b, v1.8b, v2.8b
11          sqrshl v0.16b, v1.16b, v2.16b
12          sqrshl v0.4h, v1.4h, v2.4h
13          sqrshl v0.8h, v1.8h, v2.8h
14          sqrshl v0.2s, v1.2s, v2.2s
15          sqrshl v0.4s, v1.4s, v2.4s
16          sqrshl v0.2d, v1.2d, v2.2d
17
18 // CHECK: sqrshl v0.8b, v1.8b, v2.8b        // encoding: [0x20,0x5c,0x22,0x0e]
19 // CHECK: sqrshl v0.16b, v1.16b, v2.16b     // encoding: [0x20,0x5c,0x22,0x4e]
20 // CHECK: sqrshl v0.4h, v1.4h, v2.4h        // encoding: [0x20,0x5c,0x62,0x0e]
21 // CHECK: sqrshl v0.8h, v1.8h, v2.8h        // encoding: [0x20,0x5c,0x62,0x4e]
22 // CHECK: sqrshl v0.2s, v1.2s, v2.2s        // encoding: [0x20,0x5c,0xa2,0x0e]
23 // CHECK: sqrshl v0.4s, v1.4s, v2.4s        // encoding: [0x20,0x5c,0xa2,0x4e]
24 // CHECK: sqrshl v0.2d, v1.2d, v2.2d        // encoding: [0x20,0x5c,0xe2,0x4e]
25
26 //------------------------------------------------------------------------------
27 // Vector Integer Saturating Rounding Shift Lef (Unsigned)
28 //------------------------------------------------------------------------------
29          uqrshl v0.8b, v1.8b, v2.8b
30          uqrshl v0.16b, v1.16b, v2.16b
31          uqrshl v0.4h, v1.4h, v2.4h
32          uqrshl v0.8h, v1.8h, v2.8h
33          uqrshl v0.2s, v1.2s, v2.2s
34          uqrshl v0.4s, v1.4s, v2.4s
35          uqrshl v0.2d, v1.2d, v2.2d
36
37 // CHECK: uqrshl v0.8b, v1.8b, v2.8b        // encoding: [0x20,0x5c,0x22,0x2e]
38 // CHECK: uqrshl v0.16b, v1.16b, v2.16b     // encoding: [0x20,0x5c,0x22,0x6e]
39 // CHECK: uqrshl v0.4h, v1.4h, v2.4h        // encoding: [0x20,0x5c,0x62,0x2e]
40 // CHECK: uqrshl v0.8h, v1.8h, v2.8h        // encoding: [0x20,0x5c,0x62,0x6e]
41 // CHECK: uqrshl v0.2s, v1.2s, v2.2s        // encoding: [0x20,0x5c,0xa2,0x2e]
42 // CHECK: uqrshl v0.4s, v1.4s, v2.4s        // encoding: [0x20,0x5c,0xa2,0x6e]
43 // CHECK: uqrshl v0.2d, v1.2d, v2.2d        // encoding: [0x20,0x5c,0xe2,0x6e]
44