| 1 |
// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sve2 < %s \ |
| 2 |
// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST |
| 3 |
// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sme < %s \ |
| 4 |
// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST |
| 5 |
// RUN: not llvm-mc -triple=aarch64 -show-encoding < %s 2>&1 \ |
| 6 |
// RUN: | FileCheck %s --check-prefix=CHECK-ERROR |
| 7 |
// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sve2 < %s \ |
| 8 |
// RUN: | llvm-objdump -d --mattr=+sve2 - | FileCheck %s --check-prefix=CHECK-INST |
| 9 |
// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sve2 < %s \ |
| 10 |
// RUN: | llvm-objdump -d --mattr=-sve2 - | FileCheck %s --check-prefix=CHECK-UNKNOWN |
| 11 |
|
| 12 |
uadalp z0.h, p0/m, z1.b |
| 13 |
// CHECK-INST: uadalp z0.h, p0/m, z1.b |
| 14 |
// CHECK-ENCODING: [0x20,0xa0,0x45,0x44] |
| 15 |
// CHECK-ERROR: instruction requires: sve2 or sme |
| 16 |
// CHECK-UNKNOWN: 4445a020 <unknown> |
| 17 |
|
| 18 |
uadalp z29.s, p0/m, z30.h |
| 19 |
// CHECK-INST: uadalp z29.s, p0/m, z30.h |
| 20 |
// CHECK-ENCODING: [0xdd,0xa3,0x85,0x44] |
| 21 |
// CHECK-ERROR: instruction requires: sve2 or sme |
| 22 |
// CHECK-UNKNOWN: 4485a3dd <unknown> |
| 23 |
|
| 24 |
uadalp z30.d, p7/m, z31.s |
| 25 |
// CHECK-INST: uadalp z30.d, p7/m, z31.s |
| 26 |
// CHECK-ENCODING: [0xfe,0xbf,0xc5,0x44] |
| 27 |
// CHECK-ERROR: instruction requires: sve2 or sme |
| 28 |
// CHECK-UNKNOWN: 44c5bffe <unknown> |
| 29 |
|
| 30 |
// --------------------------------------------------------------------------// |
| 31 |
// Test compatibility with MOVPRFX instruction. |
| 32 |
|
| 33 |
movprfx z31.d, p0/z, z6.d |
| 34 |
// CHECK-INST: movprfx z31.d, p0/z, z6.d |
| 35 |
// CHECK-ENCODING: [0xdf,0x20,0xd0,0x04] |
| 36 |
// CHECK-ERROR: instruction requires: sve or sme |
| 37 |
// CHECK-UNKNOWN: 04d020df <unknown> |
| 38 |
|
| 39 |
uadalp z31.d, p0/m, z30.s |
| 40 |
// CHECK-INST: uadalp z31.d, p0/m, z30.s |
| 41 |
// CHECK-ENCODING: [0xdf,0xa3,0xc5,0x44] |
| 42 |
// CHECK-ERROR: instruction requires: sve2 or sme |
| 43 |
// CHECK-UNKNOWN: 44c5a3df <unknown> |
| 44 |
|
| 45 |
movprfx z31, z6 |
| 46 |
// CHECK-INST: movprfx z31, z6 |
| 47 |
// CHECK-ENCODING: [0xdf,0xbc,0x20,0x04] |
| 48 |
// CHECK-ERROR: instruction requires: sve or sme |
| 49 |
// CHECK-UNKNOWN: 0420bcdf <unknown> |
| 50 |
|
| 51 |
uadalp z31.d, p0/m, z30.s |
| 52 |
// CHECK-INST: uadalp z31.d, p0/m, z30.s |
| 53 |
// CHECK-ENCODING: [0xdf,0xa3,0xc5,0x44] |
| 54 |
// CHECK-ERROR: instruction requires: sve2 or sme |
| 55 |
// CHECK-UNKNOWN: 44c5a3df <unknown> |