diff --git a/llvm/lib/Target/AArch64/AArch64SVEInstrInfo.td b/llvm/lib/Target/AArch64/AArch64SVEInstrInfo.td --- a/llvm/lib/Target/AArch64/AArch64SVEInstrInfo.td +++ b/llvm/lib/Target/AArch64/AArch64SVEInstrInfo.td @@ -3671,4 +3671,13 @@ defm STNT1H_4Z_IMM : sve2p1_mem_cst_si_4z<"stnt1h", 0b01, 0b1, ZZZZ_h_mul_r>; defm STNT1W_4Z_IMM : sve2p1_mem_cst_si_4z<"stnt1w", 0b10, 0b1, ZZZZ_s_mul_r>; defm STNT1D_4Z_IMM : sve2p1_mem_cst_si_4z<"stnt1d", 0b11, 0b1, ZZZZ_d_mul_r>; + +defm WHILEGE_CXX : sve2p1_int_while_rr_pn<"whilege", 0b000>; +defm WHILEGT_CXX : sve2p1_int_while_rr_pn<"whilegt", 0b001>; +defm WHILELT_CXX : sve2p1_int_while_rr_pn<"whilelt", 0b010>; +defm WHILELE_CXX : sve2p1_int_while_rr_pn<"whilele", 0b011>; +defm WHILEHS_CXX : sve2p1_int_while_rr_pn<"whilehs", 0b100>; +defm WHILEHI_CXX : sve2p1_int_while_rr_pn<"whilehi", 0b101>; +defm WHILELO_CXX : sve2p1_int_while_rr_pn<"whilelo", 0b110>; +defm WHILELS_CXX : sve2p1_int_while_rr_pn<"whilels", 0b111>; } // End HasSVE2p1_or_HasSME2 diff --git a/llvm/lib/Target/AArch64/SVEInstrFormats.td b/llvm/lib/Target/AArch64/SVEInstrFormats.td --- a/llvm/lib/Target/AArch64/SVEInstrFormats.td +++ b/llvm/lib/Target/AArch64/SVEInstrFormats.td @@ -9058,3 +9058,37 @@ def _S : sve2p1_pcount_pn; def _D : sve2p1_pcount_pn; } + + +class sve2p1_int_while_rr_pn sz, bits<3> opc, + PNRP8to15RegOp pnrty> + : I<(outs pnrty:$PNd), (ins GPR64:$Rn, GPR64:$Rm, sve_vec_len_specifier_enum:$vl), + mnemonic, "\t$PNd, $Rn, $Rm, $vl", + "", []>, Sched<[]> { + bits<3> PNd; + bits<5> Rn; + bits<1> vl; + bits<5> Rm; + let Inst{31-24} = 0b00100101; + let Inst{23-22} = sz; + let Inst{21} = 0b1; + let Inst{20-16} = Rm; + let Inst{15-14} = 0b01; + let Inst{13} = vl; + let Inst{12} = 0b0; + let Inst{11-10} = opc{2-1}; + let Inst{9-5} = Rn; + let Inst{4} = 0b1; + let Inst{3} = opc{0}; + let Inst{2-0} = PNd; + + let Defs = [NZCV]; +} + + +multiclass sve2p1_int_while_rr_pn opc> { + def _B : sve2p1_int_while_rr_pn; + def _H : sve2p1_int_while_rr_pn; + def _S : sve2p1_int_while_rr_pn; + def _D : sve2p1_int_while_rr_pn; +} diff --git a/llvm/test/MC/AArch64/SVE2p1/whilege-diagnostics.s b/llvm/test/MC/AArch64/SVE2p1/whilege-diagnostics.s new file mode 100644 --- /dev/null +++ b/llvm/test/MC/AArch64/SVE2p1/whilege-diagnostics.s @@ -0,0 +1,30 @@ +// RUN: not llvm-mc -triple=aarch64 -show-encoding -mattr=+sve2p1 2>&1 < %s | FileCheck %s + +// --------------------------------------------------------------------------// +// Invalid Pattern + +whilege pn8.b, x0, x0, vlx1 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid operand +// CHECK-NEXT: whilege pn8.b, x0, x0, vlx1 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: + +whilege pn8.b, x0, x0 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: too few operands for instruction +// CHECK-NEXT: whilege pn8.b, x0, x0 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: + +// --------------------------------------------------------------------------// +// Invalid use of predicate without suffix + +whilege pn8, x0, x0, vlx2 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: Invalid predicate register, expected PN in range pn8..pn15 with element suffix. +// CHECK-NEXT: whilege pn8, x0, x0, vlx2 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: + +// --------------------------------------------------------------------------// +// Out of range Predicate register + +whilege pn7.b, x0, x0, vlx2 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: Invalid predicate register, expected PN in range pn8..pn15 with element suffix. +// CHECK-NEXT: whilege pn7.b, x0, x0, vlx2 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: diff --git a/llvm/test/MC/AArch64/SVE2p1/whilege.s b/llvm/test/MC/AArch64/SVE2p1/whilege.s new file mode 100644 --- /dev/null +++ b/llvm/test/MC/AArch64/SVE2p1/whilege.s @@ -0,0 +1,110 @@ +// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sme2 < %s \ +// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST +// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sve2p1 < %s \ +// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST +// RUN: not llvm-mc -triple=aarch64 -show-encoding < %s 2>&1 \ +// RUN: | FileCheck %s --check-prefix=CHECK-ERROR +// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sme2 < %s \ +// RUN: | llvm-objdump -d --mattr=+sme2 - | FileCheck %s --check-prefix=CHECK-INST +// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sme2 < %s \ +// RUN: | llvm-objdump -d - | FileCheck %s --check-prefix=CHECK-UNKNOWN +// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sme2 < %s \ +// RUN: | sed '/.text/d' | sed 's/.*encoding: //g' \ +// RUN: | llvm-mc -triple=aarch64 -mattr=+sme2 -disassemble -show-encoding \ +// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST + +whilege pn8.h, x0, x0, vlx2 // 00100101-01100000-01000000-00010000 +// CHECK-INST: whilege pn8.h, x0, x0, vlx2 +// CHECK-ENCODING: [0x10,0x40,0x60,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25604010 + +whilege pn13.h, x10, x21, vlx2 // 00100101-01110101-01000001-01010101 +// CHECK-INST: whilege pn13.h, x10, x21, vlx2 +// CHECK-ENCODING: [0x55,0x41,0x75,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25754155 + +whilege pn15.h, x13, x8, vlx4 // 00100101-01101000-01100001-10110111 +// CHECK-INST: whilege pn15.h, x13, x8, vlx4 +// CHECK-ENCODING: [0xb7,0x61,0x68,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 256861b7 + +whilege pn15.h, xzr, xzr, vlx4 // 00100101-01111111-01100011-11110111 +// CHECK-INST: whilege pn15.h, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xf7,0x63,0x7f,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 257f63f7 + +whilege pn8.s, x0, x0, vlx2 // 00100101-10100000-01000000-00010000 +// CHECK-INST: whilege pn8.s, x0, x0, vlx2 +// CHECK-ENCODING: [0x10,0x40,0xa0,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25a04010 + +whilege pn13.s, x10, x21, vlx2 // 00100101-10110101-01000001-01010101 +// CHECK-INST: whilege pn13.s, x10, x21, vlx2 +// CHECK-ENCODING: [0x55,0x41,0xb5,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25b54155 + +whilege pn15.s, x13, x8, vlx4 // 00100101-10101000-01100001-10110111 +// CHECK-INST: whilege pn15.s, x13, x8, vlx4 +// CHECK-ENCODING: [0xb7,0x61,0xa8,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25a861b7 + +whilege pn15.s, xzr, xzr, vlx4 // 00100101-10111111-01100011-11110111 +// CHECK-INST: whilege pn15.s, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xf7,0x63,0xbf,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25bf63f7 + +whilege pn8.d, x0, x0, vlx2 // 00100101-11100000-01000000-00010000 +// CHECK-INST: whilege pn8.d, x0, x0, vlx2 +// CHECK-ENCODING: [0x10,0x40,0xe0,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25e04010 + +whilege pn13.d, x10, x21, vlx2 // 00100101-11110101-01000001-01010101 +// CHECK-INST: whilege pn13.d, x10, x21, vlx2 +// CHECK-ENCODING: [0x55,0x41,0xf5,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25f54155 + +whilege pn15.d, x13, x8, vlx4 // 00100101-11101000-01100001-10110111 +// CHECK-INST: whilege pn15.d, x13, x8, vlx4 +// CHECK-ENCODING: [0xb7,0x61,0xe8,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25e861b7 + +whilege pn15.d, xzr, xzr, vlx4 // 00100101-11111111-01100011-11110111 +// CHECK-INST: whilege pn15.d, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xf7,0x63,0xff,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25ff63f7 + +whilege pn8.b, x0, x0, vlx2 // 00100101-00100000-01000000-00010000 +// CHECK-INST: whilege pn8.b, x0, x0, vlx2 +// CHECK-ENCODING: [0x10,0x40,0x20,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25204010 + +whilege pn13.b, x10, x21, vlx2 // 00100101-00110101-01000001-01010101 +// CHECK-INST: whilege pn13.b, x10, x21, vlx2 +// CHECK-ENCODING: [0x55,0x41,0x35,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25354155 + +whilege pn15.b, x13, x8, vlx4 // 00100101-00101000-01100001-10110111 +// CHECK-INST: whilege pn15.b, x13, x8, vlx4 +// CHECK-ENCODING: [0xb7,0x61,0x28,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 252861b7 + +whilege pn15.b, xzr, xzr, vlx4 // 00100101-00111111-01100011-11110111 +// CHECK-INST: whilege pn15.b, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xf7,0x63,0x3f,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 253f63f7 diff --git a/llvm/test/MC/AArch64/SVE2p1/whilegt-diagnostics.s b/llvm/test/MC/AArch64/SVE2p1/whilegt-diagnostics.s new file mode 100644 --- /dev/null +++ b/llvm/test/MC/AArch64/SVE2p1/whilegt-diagnostics.s @@ -0,0 +1,30 @@ +// RUN: not llvm-mc -triple=aarch64 -show-encoding -mattr=+sve2p1 2>&1 < %s | FileCheck %s + +// --------------------------------------------------------------------------// +// Invalid Pattern + +whilegt pn8.b, x0, x0, vlx1 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid operand +// CHECK-NEXT: whilegt pn8.b, x0, x0, vlx1 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: + +whilegt pn8.b, x0, x0 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: too few operands for instruction +// CHECK-NEXT: whilegt pn8.b, x0, x0 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: + +// --------------------------------------------------------------------------// +// Invalid use of predicate without suffix + +whilegt pn8, x0, x0, vlx2 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: Invalid predicate register, expected PN in range pn8..pn15 with element suffix. +// CHECK-NEXT: whilegt pn8, x0, x0, vlx2 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: + +// --------------------------------------------------------------------------// +// Out of range Predicate register + +whilegt pn7.b, x0, x0, vlx2 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: Invalid predicate register, expected PN in range pn8..pn15 with element suffix. +// CHECK-NEXT: whilegt pn7.b, x0, x0, vlx2 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: diff --git a/llvm/test/MC/AArch64/SVE2p1/whilegt.s b/llvm/test/MC/AArch64/SVE2p1/whilegt.s new file mode 100644 --- /dev/null +++ b/llvm/test/MC/AArch64/SVE2p1/whilegt.s @@ -0,0 +1,110 @@ +// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sme2 < %s \ +// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST +// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sve2p1 < %s \ +// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST +// RUN: not llvm-mc -triple=aarch64 -show-encoding < %s 2>&1 \ +// RUN: | FileCheck %s --check-prefix=CHECK-ERROR +// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sme2 < %s \ +// RUN: | llvm-objdump -d --mattr=+sme2 - | FileCheck %s --check-prefix=CHECK-INST +// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sme2 < %s \ +// RUN: | llvm-objdump -d - | FileCheck %s --check-prefix=CHECK-UNKNOWN +// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sme2 < %s \ +// RUN: | sed '/.text/d' | sed 's/.*encoding: //g' \ +// RUN: | llvm-mc -triple=aarch64 -mattr=+sme2 -disassemble -show-encoding \ +// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST + +whilegt pn8.h, x0, x0, vlx2 // 00100101-01100000-01000000-00011000 +// CHECK-INST: whilegt pn8.h, x0, x0, vlx2 +// CHECK-ENCODING: [0x18,0x40,0x60,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25604018 + +whilegt pn13.h, x10, x21, vlx2 // 00100101-01110101-01000001-01011101 +// CHECK-INST: whilegt pn13.h, x10, x21, vlx2 +// CHECK-ENCODING: [0x5d,0x41,0x75,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 2575415d + +whilegt pn15.h, x13, x8, vlx4 // 00100101-01101000-01100001-10111111 +// CHECK-INST: whilegt pn15.h, x13, x8, vlx4 +// CHECK-ENCODING: [0xbf,0x61,0x68,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 256861bf + +whilegt pn15.h, xzr, xzr, vlx4 // 00100101-01111111-01100011-11111111 +// CHECK-INST: whilegt pn15.h, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xff,0x63,0x7f,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 257f63ff + +whilegt pn8.s, x0, x0, vlx2 // 00100101-10100000-01000000-00011000 +// CHECK-INST: whilegt pn8.s, x0, x0, vlx2 +// CHECK-ENCODING: [0x18,0x40,0xa0,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25a04018 + +whilegt pn13.s, x10, x21, vlx2 // 00100101-10110101-01000001-01011101 +// CHECK-INST: whilegt pn13.s, x10, x21, vlx2 +// CHECK-ENCODING: [0x5d,0x41,0xb5,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25b5415d + +whilegt pn15.s, x13, x8, vlx4 // 00100101-10101000-01100001-10111111 +// CHECK-INST: whilegt pn15.s, x13, x8, vlx4 +// CHECK-ENCODING: [0xbf,0x61,0xa8,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25a861bf + +whilegt pn15.s, xzr, xzr, vlx4 // 00100101-10111111-01100011-11111111 +// CHECK-INST: whilegt pn15.s, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xff,0x63,0xbf,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25bf63ff + +whilegt pn8.d, x0, x0, vlx2 // 00100101-11100000-01000000-00011000 +// CHECK-INST: whilegt pn8.d, x0, x0, vlx2 +// CHECK-ENCODING: [0x18,0x40,0xe0,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25e04018 + +whilegt pn13.d, x10, x21, vlx2 // 00100101-11110101-01000001-01011101 +// CHECK-INST: whilegt pn13.d, x10, x21, vlx2 +// CHECK-ENCODING: [0x5d,0x41,0xf5,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25f5415d + +whilegt pn15.d, x13, x8, vlx4 // 00100101-11101000-01100001-10111111 +// CHECK-INST: whilegt pn15.d, x13, x8, vlx4 +// CHECK-ENCODING: [0xbf,0x61,0xe8,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25e861bf + +whilegt pn15.d, xzr, xzr, vlx4 // 00100101-11111111-01100011-11111111 +// CHECK-INST: whilegt pn15.d, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xff,0x63,0xff,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25ff63ff + +whilegt pn8.b, x0, x0, vlx2 // 00100101-00100000-01000000-00011000 +// CHECK-INST: whilegt pn8.b, x0, x0, vlx2 +// CHECK-ENCODING: [0x18,0x40,0x20,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25204018 + +whilegt pn13.b, x10, x21, vlx2 // 00100101-00110101-01000001-01011101 +// CHECK-INST: whilegt pn13.b, x10, x21, vlx2 +// CHECK-ENCODING: [0x5d,0x41,0x35,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 2535415d + +whilegt pn15.b, x13, x8, vlx4 // 00100101-00101000-01100001-10111111 +// CHECK-INST: whilegt pn15.b, x13, x8, vlx4 +// CHECK-ENCODING: [0xbf,0x61,0x28,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 252861bf + +whilegt pn15.b, xzr, xzr, vlx4 // 00100101-00111111-01100011-11111111 +// CHECK-INST: whilegt pn15.b, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xff,0x63,0x3f,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 253f63ff diff --git a/llvm/test/MC/AArch64/SVE2p1/whilehi-diagnostics.s b/llvm/test/MC/AArch64/SVE2p1/whilehi-diagnostics.s new file mode 100644 --- /dev/null +++ b/llvm/test/MC/AArch64/SVE2p1/whilehi-diagnostics.s @@ -0,0 +1,30 @@ +// RUN: not llvm-mc -triple=aarch64 -show-encoding -mattr=+sve2p1 2>&1 < %s | FileCheck %s + +// --------------------------------------------------------------------------// +// Invalid Pattern + +whilehi pn8.b, x0, x0, vlx1 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid operand +// CHECK-NEXT: whilehi pn8.b, x0, x0, vlx1 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: + +whilehi pn8.b, x0, x0 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: too few operands for instruction +// CHECK-NEXT: whilehi pn8.b, x0, x0 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: + +// --------------------------------------------------------------------------// +// Invalid use of predicate without suffix + +whilehi pn8, x0, x0, vlx2 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: Invalid predicate register, expected PN in range pn8..pn15 with element suffix. +// CHECK-NEXT: whilehi pn8, x0, x0, vlx2 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: + +// --------------------------------------------------------------------------// +// Out of range Predicate register + +whilehi pn7.b, x0, x0, vlx2 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: Invalid predicate register, expected PN in range pn8..pn15 with element suffix. +// CHECK-NEXT: whilehi pn7.b, x0, x0, vlx2 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: diff --git a/llvm/test/MC/AArch64/SVE2p1/whilehi.s b/llvm/test/MC/AArch64/SVE2p1/whilehi.s new file mode 100644 --- /dev/null +++ b/llvm/test/MC/AArch64/SVE2p1/whilehi.s @@ -0,0 +1,110 @@ +// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sme2 < %s \ +// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST +// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sve2p1 < %s \ +// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST +// RUN: not llvm-mc -triple=aarch64 -show-encoding < %s 2>&1 \ +// RUN: | FileCheck %s --check-prefix=CHECK-ERROR +// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sme2 < %s \ +// RUN: | llvm-objdump -d --mattr=+sme2 - | FileCheck %s --check-prefix=CHECK-INST +// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sme2 < %s \ +// RUN: | llvm-objdump -d - | FileCheck %s --check-prefix=CHECK-UNKNOWN +// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sme2 < %s \ +// RUN: | sed '/.text/d' | sed 's/.*encoding: //g' \ +// RUN: | llvm-mc -triple=aarch64 -mattr=+sme2 -disassemble -show-encoding \ +// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST + +whilehi pn8.h, x0, x0, vlx2 // 00100101-01100000-01001000-00011000 +// CHECK-INST: whilehi pn8.h, x0, x0, vlx2 +// CHECK-ENCODING: [0x18,0x48,0x60,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25604818 + +whilehi pn13.h, x10, x21, vlx2 // 00100101-01110101-01001001-01011101 +// CHECK-INST: whilehi pn13.h, x10, x21, vlx2 +// CHECK-ENCODING: [0x5d,0x49,0x75,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 2575495d + +whilehi pn15.h, x13, x8, vlx4 // 00100101-01101000-01101001-10111111 +// CHECK-INST: whilehi pn15.h, x13, x8, vlx4 +// CHECK-ENCODING: [0xbf,0x69,0x68,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 256869bf + +whilehi pn15.h, xzr, xzr, vlx4 // 00100101-01111111-01101011-11111111 +// CHECK-INST: whilehi pn15.h, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xff,0x6b,0x7f,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 257f6bff + +whilehi pn8.s, x0, x0, vlx2 // 00100101-10100000-01001000-00011000 +// CHECK-INST: whilehi pn8.s, x0, x0, vlx2 +// CHECK-ENCODING: [0x18,0x48,0xa0,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25a04818 + +whilehi pn13.s, x10, x21, vlx2 // 00100101-10110101-01001001-01011101 +// CHECK-INST: whilehi pn13.s, x10, x21, vlx2 +// CHECK-ENCODING: [0x5d,0x49,0xb5,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25b5495d + +whilehi pn15.s, x13, x8, vlx4 // 00100101-10101000-01101001-10111111 +// CHECK-INST: whilehi pn15.s, x13, x8, vlx4 +// CHECK-ENCODING: [0xbf,0x69,0xa8,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25a869bf + +whilehi pn15.s, xzr, xzr, vlx4 // 00100101-10111111-01101011-11111111 +// CHECK-INST: whilehi pn15.s, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xff,0x6b,0xbf,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25bf6bff + +whilehi pn8.d, x0, x0, vlx2 // 00100101-11100000-01001000-00011000 +// CHECK-INST: whilehi pn8.d, x0, x0, vlx2 +// CHECK-ENCODING: [0x18,0x48,0xe0,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25e04818 + +whilehi pn13.d, x10, x21, vlx2 // 00100101-11110101-01001001-01011101 +// CHECK-INST: whilehi pn13.d, x10, x21, vlx2 +// CHECK-ENCODING: [0x5d,0x49,0xf5,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25f5495d + +whilehi pn15.d, x13, x8, vlx4 // 00100101-11101000-01101001-10111111 +// CHECK-INST: whilehi pn15.d, x13, x8, vlx4 +// CHECK-ENCODING: [0xbf,0x69,0xe8,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25e869bf + +whilehi pn15.d, xzr, xzr, vlx4 // 00100101-11111111-01101011-11111111 +// CHECK-INST: whilehi pn15.d, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xff,0x6b,0xff,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25ff6bff + +whilehi pn8.b, x0, x0, vlx2 // 00100101-00100000-01001000-00011000 +// CHECK-INST: whilehi pn8.b, x0, x0, vlx2 +// CHECK-ENCODING: [0x18,0x48,0x20,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25204818 + +whilehi pn13.b, x10, x21, vlx2 // 00100101-00110101-01001001-01011101 +// CHECK-INST: whilehi pn13.b, x10, x21, vlx2 +// CHECK-ENCODING: [0x5d,0x49,0x35,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 2535495d + +whilehi pn15.b, x13, x8, vlx4 // 00100101-00101000-01101001-10111111 +// CHECK-INST: whilehi pn15.b, x13, x8, vlx4 +// CHECK-ENCODING: [0xbf,0x69,0x28,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 252869bf + +whilehi pn15.b, xzr, xzr, vlx4 // 00100101-00111111-01101011-11111111 +// CHECK-INST: whilehi pn15.b, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xff,0x6b,0x3f,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 253f6bff diff --git a/llvm/test/MC/AArch64/SVE2p1/whilehs-diagnostics.s b/llvm/test/MC/AArch64/SVE2p1/whilehs-diagnostics.s new file mode 100644 --- /dev/null +++ b/llvm/test/MC/AArch64/SVE2p1/whilehs-diagnostics.s @@ -0,0 +1,30 @@ +// RUN: not llvm-mc -triple=aarch64 -show-encoding -mattr=+sve2p1 2>&1 < %s | FileCheck %s + +// --------------------------------------------------------------------------// +// Invalid Pattern + +whilehs pn8.b, x0, x0, vlx1 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid operand +// CHECK-NEXT: whilehs pn8.b, x0, x0, vlx1 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: + +whilehs pn8.b, x0, x0 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: too few operands for instruction +// CHECK-NEXT: whilehs pn8.b, x0, x0 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: + +// --------------------------------------------------------------------------// +// Invalid use of predicate without suffix + +whilehs pn8, x0, x0, vlx2 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: Invalid predicate register, expected PN in range pn8..pn15 with element suffix. +// CHECK-NEXT: whilehs pn8, x0, x0, vlx2 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: + +// --------------------------------------------------------------------------// +// Out of range Predicate register + +whilehs pn7.b, x0, x0, vlx2 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: Invalid predicate register, expected PN in range pn8..pn15 with element suffix. +// CHECK-NEXT: whilehs pn7.b, x0, x0, vlx2 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: diff --git a/llvm/test/MC/AArch64/SVE2p1/whilehs.s b/llvm/test/MC/AArch64/SVE2p1/whilehs.s new file mode 100644 --- /dev/null +++ b/llvm/test/MC/AArch64/SVE2p1/whilehs.s @@ -0,0 +1,110 @@ +// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sme2 < %s \ +// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST +// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sve2p1 < %s \ +// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST +// RUN: not llvm-mc -triple=aarch64 -show-encoding < %s 2>&1 \ +// RUN: | FileCheck %s --check-prefix=CHECK-ERROR +// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sme2 < %s \ +// RUN: | llvm-objdump -d --mattr=+sme2 - | FileCheck %s --check-prefix=CHECK-INST +// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sme2 < %s \ +// RUN: | llvm-objdump -d - | FileCheck %s --check-prefix=CHECK-UNKNOWN +// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sme2 < %s \ +// RUN: | sed '/.text/d' | sed 's/.*encoding: //g' \ +// RUN: | llvm-mc -triple=aarch64 -mattr=+sme2 -disassemble -show-encoding \ +// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST + +whilehs pn8.h, x0, x0, vlx2 // 00100101-01100000-01001000-00010000 +// CHECK-INST: whilehs pn8.h, x0, x0, vlx2 +// CHECK-ENCODING: [0x10,0x48,0x60,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25604810 + +whilehs pn13.h, x10, x21, vlx2 // 00100101-01110101-01001001-01010101 +// CHECK-INST: whilehs pn13.h, x10, x21, vlx2 +// CHECK-ENCODING: [0x55,0x49,0x75,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25754955 + +whilehs pn15.h, x13, x8, vlx4 // 00100101-01101000-01101001-10110111 +// CHECK-INST: whilehs pn15.h, x13, x8, vlx4 +// CHECK-ENCODING: [0xb7,0x69,0x68,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 256869b7 + +whilehs pn15.h, xzr, xzr, vlx4 // 00100101-01111111-01101011-11110111 +// CHECK-INST: whilehs pn15.h, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xf7,0x6b,0x7f,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 257f6bf7 + +whilehs pn8.s, x0, x0, vlx2 // 00100101-10100000-01001000-00010000 +// CHECK-INST: whilehs pn8.s, x0, x0, vlx2 +// CHECK-ENCODING: [0x10,0x48,0xa0,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25a04810 + +whilehs pn13.s, x10, x21, vlx2 // 00100101-10110101-01001001-01010101 +// CHECK-INST: whilehs pn13.s, x10, x21, vlx2 +// CHECK-ENCODING: [0x55,0x49,0xb5,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25b54955 + +whilehs pn15.s, x13, x8, vlx4 // 00100101-10101000-01101001-10110111 +// CHECK-INST: whilehs pn15.s, x13, x8, vlx4 +// CHECK-ENCODING: [0xb7,0x69,0xa8,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25a869b7 + +whilehs pn15.s, xzr, xzr, vlx4 // 00100101-10111111-01101011-11110111 +// CHECK-INST: whilehs pn15.s, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xf7,0x6b,0xbf,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25bf6bf7 + +whilehs pn8.d, x0, x0, vlx2 // 00100101-11100000-01001000-00010000 +// CHECK-INST: whilehs pn8.d, x0, x0, vlx2 +// CHECK-ENCODING: [0x10,0x48,0xe0,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25e04810 + +whilehs pn13.d, x10, x21, vlx2 // 00100101-11110101-01001001-01010101 +// CHECK-INST: whilehs pn13.d, x10, x21, vlx2 +// CHECK-ENCODING: [0x55,0x49,0xf5,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25f54955 + +whilehs pn15.d, x13, x8, vlx4 // 00100101-11101000-01101001-10110111 +// CHECK-INST: whilehs pn15.d, x13, x8, vlx4 +// CHECK-ENCODING: [0xb7,0x69,0xe8,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25e869b7 + +whilehs pn15.d, xzr, xzr, vlx4 // 00100101-11111111-01101011-11110111 +// CHECK-INST: whilehs pn15.d, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xf7,0x6b,0xff,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25ff6bf7 + +whilehs pn8.b, x0, x0, vlx2 // 00100101-00100000-01001000-00010000 +// CHECK-INST: whilehs pn8.b, x0, x0, vlx2 +// CHECK-ENCODING: [0x10,0x48,0x20,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25204810 + +whilehs pn13.b, x10, x21, vlx2 // 00100101-00110101-01001001-01010101 +// CHECK-INST: whilehs pn13.b, x10, x21, vlx2 +// CHECK-ENCODING: [0x55,0x49,0x35,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25354955 + +whilehs pn15.b, x13, x8, vlx4 // 00100101-00101000-01101001-10110111 +// CHECK-INST: whilehs pn15.b, x13, x8, vlx4 +// CHECK-ENCODING: [0xb7,0x69,0x28,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 252869b7 + +whilehs pn15.b, xzr, xzr, vlx4 // 00100101-00111111-01101011-11110111 +// CHECK-INST: whilehs pn15.b, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xf7,0x6b,0x3f,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 253f6bf7 diff --git a/llvm/test/MC/AArch64/SVE2p1/whilele-diagnostics.s b/llvm/test/MC/AArch64/SVE2p1/whilele-diagnostics.s new file mode 100644 --- /dev/null +++ b/llvm/test/MC/AArch64/SVE2p1/whilele-diagnostics.s @@ -0,0 +1,30 @@ +// RUN: not llvm-mc -triple=aarch64 -show-encoding -mattr=+sve2p1 2>&1 < %s | FileCheck %s + +// --------------------------------------------------------------------------// +// Invalid Pattern + +whilele pn8.b, x0, x0, vlx1 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid operand +// CHECK-NEXT: whilele pn8.b, x0, x0, vlx1 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: + +whilele pn8.b, x0, x0 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: too few operands for instruction +// CHECK-NEXT: whilele pn8.b, x0, x0 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: + +// --------------------------------------------------------------------------// +// Invalid use of predicate without suffix + +whilele pn8, x0, x0, vlx2 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: Invalid predicate register, expected PN in range pn8..pn15 with element suffix. +// CHECK-NEXT: whilele pn8, x0, x0, vlx2 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: + +// --------------------------------------------------------------------------// +// Out of range Predicate register + +whilele pn7.b, x0, x0, vlx2 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: Invalid predicate register, expected PN in range pn8..pn15 with element suffix. +// CHECK-NEXT: whilele pn7.b, x0, x0, vlx2 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: diff --git a/llvm/test/MC/AArch64/SVE2p1/whilele.s b/llvm/test/MC/AArch64/SVE2p1/whilele.s new file mode 100644 --- /dev/null +++ b/llvm/test/MC/AArch64/SVE2p1/whilele.s @@ -0,0 +1,110 @@ +// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sme2 < %s \ +// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST +// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sve2p1 < %s \ +// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST +// RUN: not llvm-mc -triple=aarch64 -show-encoding < %s 2>&1 \ +// RUN: | FileCheck %s --check-prefix=CHECK-ERROR +// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sme2 < %s \ +// RUN: | llvm-objdump -d --mattr=+sme2 - | FileCheck %s --check-prefix=CHECK-INST +// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sme2 < %s \ +// RUN: | llvm-objdump -d - | FileCheck %s --check-prefix=CHECK-UNKNOWN +// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sme2 < %s \ +// RUN: | sed '/.text/d' | sed 's/.*encoding: //g' \ +// RUN: | llvm-mc -triple=aarch64 -mattr=+sme2 -disassemble -show-encoding \ +// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST + +whilele pn8.h, x0, x0, vlx2 // 00100101-01100000-01000100-00011000 +// CHECK-INST: whilele pn8.h, x0, x0, vlx2 +// CHECK-ENCODING: [0x18,0x44,0x60,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25604418 + +whilele pn13.h, x10, x21, vlx2 // 00100101-01110101-01000101-01011101 +// CHECK-INST: whilele pn13.h, x10, x21, vlx2 +// CHECK-ENCODING: [0x5d,0x45,0x75,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 2575455d + +whilele pn15.h, x13, x8, vlx4 // 00100101-01101000-01100101-10111111 +// CHECK-INST: whilele pn15.h, x13, x8, vlx4 +// CHECK-ENCODING: [0xbf,0x65,0x68,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 256865bf + +whilele pn15.h, xzr, xzr, vlx4 // 00100101-01111111-01100111-11111111 +// CHECK-INST: whilele pn15.h, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xff,0x67,0x7f,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 257f67ff + +whilele pn8.s, x0, x0, vlx2 // 00100101-10100000-01000100-00011000 +// CHECK-INST: whilele pn8.s, x0, x0, vlx2 +// CHECK-ENCODING: [0x18,0x44,0xa0,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25a04418 + +whilele pn13.s, x10, x21, vlx2 // 00100101-10110101-01000101-01011101 +// CHECK-INST: whilele pn13.s, x10, x21, vlx2 +// CHECK-ENCODING: [0x5d,0x45,0xb5,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25b5455d + +whilele pn15.s, x13, x8, vlx4 // 00100101-10101000-01100101-10111111 +// CHECK-INST: whilele pn15.s, x13, x8, vlx4 +// CHECK-ENCODING: [0xbf,0x65,0xa8,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25a865bf + +whilele pn15.s, xzr, xzr, vlx4 // 00100101-10111111-01100111-11111111 +// CHECK-INST: whilele pn15.s, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xff,0x67,0xbf,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25bf67ff + +whilele pn8.d, x0, x0, vlx2 // 00100101-11100000-01000100-00011000 +// CHECK-INST: whilele pn8.d, x0, x0, vlx2 +// CHECK-ENCODING: [0x18,0x44,0xe0,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25e04418 + +whilele pn13.d, x10, x21, vlx2 // 00100101-11110101-01000101-01011101 +// CHECK-INST: whilele pn13.d, x10, x21, vlx2 +// CHECK-ENCODING: [0x5d,0x45,0xf5,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25f5455d + +whilele pn15.d, x13, x8, vlx4 // 00100101-11101000-01100101-10111111 +// CHECK-INST: whilele pn15.d, x13, x8, vlx4 +// CHECK-ENCODING: [0xbf,0x65,0xe8,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25e865bf + +whilele pn15.d, xzr, xzr, vlx4 // 00100101-11111111-01100111-11111111 +// CHECK-INST: whilele pn15.d, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xff,0x67,0xff,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25ff67ff + +whilele pn8.b, x0, x0, vlx2 // 00100101-00100000-01000100-00011000 +// CHECK-INST: whilele pn8.b, x0, x0, vlx2 +// CHECK-ENCODING: [0x18,0x44,0x20,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25204418 + +whilele pn13.b, x10, x21, vlx2 // 00100101-00110101-01000101-01011101 +// CHECK-INST: whilele pn13.b, x10, x21, vlx2 +// CHECK-ENCODING: [0x5d,0x45,0x35,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 2535455d + +whilele pn15.b, x13, x8, vlx4 // 00100101-00101000-01100101-10111111 +// CHECK-INST: whilele pn15.b, x13, x8, vlx4 +// CHECK-ENCODING: [0xbf,0x65,0x28,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 252865bf + +whilele pn15.b, xzr, xzr, vlx4 // 00100101-00111111-01100111-11111111 +// CHECK-INST: whilele pn15.b, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xff,0x67,0x3f,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 253f67ff diff --git a/llvm/test/MC/AArch64/SVE2p1/whilelo-diagnostics.s b/llvm/test/MC/AArch64/SVE2p1/whilelo-diagnostics.s new file mode 100644 --- /dev/null +++ b/llvm/test/MC/AArch64/SVE2p1/whilelo-diagnostics.s @@ -0,0 +1,30 @@ +// RUN: not llvm-mc -triple=aarch64 -show-encoding -mattr=+sve2p1 2>&1 < %s | FileCheck %s + +// --------------------------------------------------------------------------// +// Invalid Pattern + +whilelo pn8.b, x0, x0, vlx1 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid operand +// CHECK-NEXT: whilelo pn8.b, x0, x0, vlx1 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: + +whilelo pn8.b, x0, x0 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: too few operands for instruction +// CHECK-NEXT: whilelo pn8.b, x0, x0 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: + +// --------------------------------------------------------------------------// +// Invalid use of predicate without suffix + +whilelo pn8, x0, x0, vlx2 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: Invalid predicate register, expected PN in range pn8..pn15 with element suffix. +// CHECK-NEXT: whilelo pn8, x0, x0, vlx2 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: + +// --------------------------------------------------------------------------// +// Out of range Predicate register + +whilelo pn7.b, x0, x0, vlx2 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: Invalid predicate register, expected PN in range pn8..pn15 with element suffix. +// CHECK-NEXT: whilelo pn7.b, x0, x0, vlx2 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: diff --git a/llvm/test/MC/AArch64/SVE2p1/whilelo.s b/llvm/test/MC/AArch64/SVE2p1/whilelo.s new file mode 100644 --- /dev/null +++ b/llvm/test/MC/AArch64/SVE2p1/whilelo.s @@ -0,0 +1,110 @@ +// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sme2 < %s \ +// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST +// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sve2p1 < %s \ +// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST +// RUN: not llvm-mc -triple=aarch64 -show-encoding < %s 2>&1 \ +// RUN: | FileCheck %s --check-prefix=CHECK-ERROR +// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sme2 < %s \ +// RUN: | llvm-objdump -d --mattr=+sme2 - | FileCheck %s --check-prefix=CHECK-INST +// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sme2 < %s \ +// RUN: | llvm-objdump -d - | FileCheck %s --check-prefix=CHECK-UNKNOWN +// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sme2 < %s \ +// RUN: | sed '/.text/d' | sed 's/.*encoding: //g' \ +// RUN: | llvm-mc -triple=aarch64 -mattr=+sme2 -disassemble -show-encoding \ +// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST + +whilelo pn8.h, x0, x0, vlx2 // 00100101-01100000-01001100-00010000 +// CHECK-INST: whilelo pn8.h, x0, x0, vlx2 +// CHECK-ENCODING: [0x10,0x4c,0x60,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25604c10 + +whilelo pn13.h, x10, x21, vlx2 // 00100101-01110101-01001101-01010101 +// CHECK-INST: whilelo pn13.h, x10, x21, vlx2 +// CHECK-ENCODING: [0x55,0x4d,0x75,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25754d55 + +whilelo pn15.h, x13, x8, vlx4 // 00100101-01101000-01101101-10110111 +// CHECK-INST: whilelo pn15.h, x13, x8, vlx4 +// CHECK-ENCODING: [0xb7,0x6d,0x68,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25686db7 + +whilelo pn15.h, xzr, xzr, vlx4 // 00100101-01111111-01101111-11110111 +// CHECK-INST: whilelo pn15.h, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xf7,0x6f,0x7f,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 257f6ff7 + +whilelo pn8.s, x0, x0, vlx2 // 00100101-10100000-01001100-00010000 +// CHECK-INST: whilelo pn8.s, x0, x0, vlx2 +// CHECK-ENCODING: [0x10,0x4c,0xa0,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25a04c10 + +whilelo pn13.s, x10, x21, vlx2 // 00100101-10110101-01001101-01010101 +// CHECK-INST: whilelo pn13.s, x10, x21, vlx2 +// CHECK-ENCODING: [0x55,0x4d,0xb5,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25b54d55 + +whilelo pn15.s, x13, x8, vlx4 // 00100101-10101000-01101101-10110111 +// CHECK-INST: whilelo pn15.s, x13, x8, vlx4 +// CHECK-ENCODING: [0xb7,0x6d,0xa8,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25a86db7 + +whilelo pn15.s, xzr, xzr, vlx4 // 00100101-10111111-01101111-11110111 +// CHECK-INST: whilelo pn15.s, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xf7,0x6f,0xbf,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25bf6ff7 + +whilelo pn8.d, x0, x0, vlx2 // 00100101-11100000-01001100-00010000 +// CHECK-INST: whilelo pn8.d, x0, x0, vlx2 +// CHECK-ENCODING: [0x10,0x4c,0xe0,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25e04c10 + +whilelo pn13.d, x10, x21, vlx2 // 00100101-11110101-01001101-01010101 +// CHECK-INST: whilelo pn13.d, x10, x21, vlx2 +// CHECK-ENCODING: [0x55,0x4d,0xf5,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25f54d55 + +whilelo pn15.d, x13, x8, vlx4 // 00100101-11101000-01101101-10110111 +// CHECK-INST: whilelo pn15.d, x13, x8, vlx4 +// CHECK-ENCODING: [0xb7,0x6d,0xe8,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25e86db7 + +whilelo pn15.d, xzr, xzr, vlx4 // 00100101-11111111-01101111-11110111 +// CHECK-INST: whilelo pn15.d, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xf7,0x6f,0xff,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25ff6ff7 + +whilelo pn8.b, x0, x0, vlx2 // 00100101-00100000-01001100-00010000 +// CHECK-INST: whilelo pn8.b, x0, x0, vlx2 +// CHECK-ENCODING: [0x10,0x4c,0x20,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25204c10 + +whilelo pn13.b, x10, x21, vlx2 // 00100101-00110101-01001101-01010101 +// CHECK-INST: whilelo pn13.b, x10, x21, vlx2 +// CHECK-ENCODING: [0x55,0x4d,0x35,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25354d55 + +whilelo pn15.b, x13, x8, vlx4 // 00100101-00101000-01101101-10110111 +// CHECK-INST: whilelo pn15.b, x13, x8, vlx4 +// CHECK-ENCODING: [0xb7,0x6d,0x28,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25286db7 + +whilelo pn15.b, xzr, xzr, vlx4 // 00100101-00111111-01101111-11110111 +// CHECK-INST: whilelo pn15.b, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xf7,0x6f,0x3f,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 253f6ff7 diff --git a/llvm/test/MC/AArch64/SVE2p1/whilels-diagnostics.s b/llvm/test/MC/AArch64/SVE2p1/whilels-diagnostics.s new file mode 100644 --- /dev/null +++ b/llvm/test/MC/AArch64/SVE2p1/whilels-diagnostics.s @@ -0,0 +1,30 @@ +// RUN: not llvm-mc -triple=aarch64 -show-encoding -mattr=+sve2p1 2>&1 < %s | FileCheck %s + +// --------------------------------------------------------------------------// +// Invalid Pattern + +whilels pn8.b, x0, x0, vlx1 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid operand +// CHECK-NEXT: whilels pn8.b, x0, x0, vlx1 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: + +whilels pn8.b, x0, x0 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: too few operands for instruction +// CHECK-NEXT: whilels pn8.b, x0, x0 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: + +// --------------------------------------------------------------------------// +// Invalid use of predicate without suffix + +whilels pn8, x0, x0, vlx2 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: Invalid predicate register, expected PN in range pn8..pn15 with element suffix. +// CHECK-NEXT: whilels pn8, x0, x0, vlx2 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: + +// --------------------------------------------------------------------------// +// Out of range Predicate register + +whilels pn7.b, x0, x0, vlx2 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: Invalid predicate register, expected PN in range pn8..pn15 with element suffix. +// CHECK-NEXT: whilels pn7.b, x0, x0, vlx2 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: diff --git a/llvm/test/MC/AArch64/SVE2p1/whilels.s b/llvm/test/MC/AArch64/SVE2p1/whilels.s new file mode 100644 --- /dev/null +++ b/llvm/test/MC/AArch64/SVE2p1/whilels.s @@ -0,0 +1,110 @@ +// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sme2 < %s \ +// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST +// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sve2p1 < %s \ +// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST +// RUN: not llvm-mc -triple=aarch64 -show-encoding < %s 2>&1 \ +// RUN: | FileCheck %s --check-prefix=CHECK-ERROR +// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sme2 < %s \ +// RUN: | llvm-objdump -d --mattr=+sme2 - | FileCheck %s --check-prefix=CHECK-INST +// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sme2 < %s \ +// RUN: | llvm-objdump -d - | FileCheck %s --check-prefix=CHECK-UNKNOWN +// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sme2 < %s \ +// RUN: | sed '/.text/d' | sed 's/.*encoding: //g' \ +// RUN: | llvm-mc -triple=aarch64 -mattr=+sme2 -disassemble -show-encoding \ +// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST + +whilels pn8.h, x0, x0, vlx2 // 00100101-01100000-01001100-00011000 +// CHECK-INST: whilels pn8.h, x0, x0, vlx2 +// CHECK-ENCODING: [0x18,0x4c,0x60,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25604c18 + +whilels pn13.h, x10, x21, vlx2 // 00100101-01110101-01001101-01011101 +// CHECK-INST: whilels pn13.h, x10, x21, vlx2 +// CHECK-ENCODING: [0x5d,0x4d,0x75,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25754d5d + +whilels pn15.h, x13, x8, vlx4 // 00100101-01101000-01101101-10111111 +// CHECK-INST: whilels pn15.h, x13, x8, vlx4 +// CHECK-ENCODING: [0xbf,0x6d,0x68,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25686dbf + +whilels pn15.h, xzr, xzr, vlx4 // 00100101-01111111-01101111-11111111 +// CHECK-INST: whilels pn15.h, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xff,0x6f,0x7f,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 257f6fff + +whilels pn8.s, x0, x0, vlx2 // 00100101-10100000-01001100-00011000 +// CHECK-INST: whilels pn8.s, x0, x0, vlx2 +// CHECK-ENCODING: [0x18,0x4c,0xa0,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25a04c18 + +whilels pn13.s, x10, x21, vlx2 // 00100101-10110101-01001101-01011101 +// CHECK-INST: whilels pn13.s, x10, x21, vlx2 +// CHECK-ENCODING: [0x5d,0x4d,0xb5,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25b54d5d + +whilels pn15.s, x13, x8, vlx4 // 00100101-10101000-01101101-10111111 +// CHECK-INST: whilels pn15.s, x13, x8, vlx4 +// CHECK-ENCODING: [0xbf,0x6d,0xa8,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25a86dbf + +whilels pn15.s, xzr, xzr, vlx4 // 00100101-10111111-01101111-11111111 +// CHECK-INST: whilels pn15.s, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xff,0x6f,0xbf,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25bf6fff + +whilels pn8.d, x0, x0, vlx2 // 00100101-11100000-01001100-00011000 +// CHECK-INST: whilels pn8.d, x0, x0, vlx2 +// CHECK-ENCODING: [0x18,0x4c,0xe0,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25e04c18 + +whilels pn13.d, x10, x21, vlx2 // 00100101-11110101-01001101-01011101 +// CHECK-INST: whilels pn13.d, x10, x21, vlx2 +// CHECK-ENCODING: [0x5d,0x4d,0xf5,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25f54d5d + +whilels pn15.d, x13, x8, vlx4 // 00100101-11101000-01101101-10111111 +// CHECK-INST: whilels pn15.d, x13, x8, vlx4 +// CHECK-ENCODING: [0xbf,0x6d,0xe8,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25e86dbf + +whilels pn15.d, xzr, xzr, vlx4 // 00100101-11111111-01101111-11111111 +// CHECK-INST: whilels pn15.d, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xff,0x6f,0xff,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25ff6fff + +whilels pn8.b, x0, x0, vlx2 // 00100101-00100000-01001100-00011000 +// CHECK-INST: whilels pn8.b, x0, x0, vlx2 +// CHECK-ENCODING: [0x18,0x4c,0x20,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25204c18 + +whilels pn13.b, x10, x21, vlx2 // 00100101-00110101-01001101-01011101 +// CHECK-INST: whilels pn13.b, x10, x21, vlx2 +// CHECK-ENCODING: [0x5d,0x4d,0x35,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25354d5d + +whilels pn15.b, x13, x8, vlx4 // 00100101-00101000-01101101-10111111 +// CHECK-INST: whilels pn15.b, x13, x8, vlx4 +// CHECK-ENCODING: [0xbf,0x6d,0x28,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25286dbf + +whilels pn15.b, xzr, xzr, vlx4 // 00100101-00111111-01101111-11111111 +// CHECK-INST: whilels pn15.b, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xff,0x6f,0x3f,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 253f6fff diff --git a/llvm/test/MC/AArch64/SVE2p1/whilelt-diagnostics.s b/llvm/test/MC/AArch64/SVE2p1/whilelt-diagnostics.s new file mode 100644 --- /dev/null +++ b/llvm/test/MC/AArch64/SVE2p1/whilelt-diagnostics.s @@ -0,0 +1,30 @@ +// RUN: not llvm-mc -triple=aarch64 -show-encoding -mattr=+sve2p1 2>&1 < %s | FileCheck %s + +// --------------------------------------------------------------------------// +// Invalid Pattern + +whilelt pn8.b, x0, x0, vlx1 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid operand +// CHECK-NEXT: whilelt pn8.b, x0, x0, vlx1 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: + +whilelt pn8.b, x0, x0 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: too few operands for instruction +// CHECK-NEXT: whilelt pn8.b, x0, x0 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: + +// --------------------------------------------------------------------------// +// Invalid use of predicate without suffix + +whilelt pn8, x0, x0, vlx2 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: Invalid predicate register, expected PN in range pn8..pn15 with element suffix. +// CHECK-NEXT: whilelt pn8, x0, x0, vlx2 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: + +// --------------------------------------------------------------------------// +// Out of range Predicate register + +whilelt pn7.b, x0, x0, vlx2 +// CHECK: [[@LINE-1]]:{{[0-9]+}}: error: Invalid predicate register, expected PN in range pn8..pn15 with element suffix. +// CHECK-NEXT: whilelt pn7.b, x0, x0, vlx2 +// CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: diff --git a/llvm/test/MC/AArch64/SVE2p1/whilelt.s b/llvm/test/MC/AArch64/SVE2p1/whilelt.s new file mode 100644 --- /dev/null +++ b/llvm/test/MC/AArch64/SVE2p1/whilelt.s @@ -0,0 +1,110 @@ +// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sme2 < %s \ +// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST +// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sve2p1 < %s \ +// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST +// RUN: not llvm-mc -triple=aarch64 -show-encoding < %s 2>&1 \ +// RUN: | FileCheck %s --check-prefix=CHECK-ERROR +// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sme2 < %s \ +// RUN: | llvm-objdump -d --mattr=+sme2 - | FileCheck %s --check-prefix=CHECK-INST +// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sme2 < %s \ +// RUN: | llvm-objdump -d - | FileCheck %s --check-prefix=CHECK-UNKNOWN +// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sme2 < %s \ +// RUN: | sed '/.text/d' | sed 's/.*encoding: //g' \ +// RUN: | llvm-mc -triple=aarch64 -mattr=+sme2 -disassemble -show-encoding \ +// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST + +whilelt pn8.h, x0, x0, vlx2 // 00100101-01100000-01000100-00010000 +// CHECK-INST: whilelt pn8.h, x0, x0, vlx2 +// CHECK-ENCODING: [0x10,0x44,0x60,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25604410 + +whilelt pn13.h, x10, x21, vlx2 // 00100101-01110101-01000101-01010101 +// CHECK-INST: whilelt pn13.h, x10, x21, vlx2 +// CHECK-ENCODING: [0x55,0x45,0x75,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25754555 + +whilelt pn15.h, x13, x8, vlx4 // 00100101-01101000-01100101-10110111 +// CHECK-INST: whilelt pn15.h, x13, x8, vlx4 +// CHECK-ENCODING: [0xb7,0x65,0x68,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 256865b7 + +whilelt pn15.h, xzr, xzr, vlx4 // 00100101-01111111-01100111-11110111 +// CHECK-INST: whilelt pn15.h, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xf7,0x67,0x7f,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 257f67f7 + +whilelt pn8.s, x0, x0, vlx2 // 00100101-10100000-01000100-00010000 +// CHECK-INST: whilelt pn8.s, x0, x0, vlx2 +// CHECK-ENCODING: [0x10,0x44,0xa0,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25a04410 + +whilelt pn13.s, x10, x21, vlx2 // 00100101-10110101-01000101-01010101 +// CHECK-INST: whilelt pn13.s, x10, x21, vlx2 +// CHECK-ENCODING: [0x55,0x45,0xb5,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25b54555 + +whilelt pn15.s, x13, x8, vlx4 // 00100101-10101000-01100101-10110111 +// CHECK-INST: whilelt pn15.s, x13, x8, vlx4 +// CHECK-ENCODING: [0xb7,0x65,0xa8,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25a865b7 + +whilelt pn15.s, xzr, xzr, vlx4 // 00100101-10111111-01100111-11110111 +// CHECK-INST: whilelt pn15.s, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xf7,0x67,0xbf,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25bf67f7 + +whilelt pn8.d, x0, x0, vlx2 // 00100101-11100000-01000100-00010000 +// CHECK-INST: whilelt pn8.d, x0, x0, vlx2 +// CHECK-ENCODING: [0x10,0x44,0xe0,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25e04410 + +whilelt pn13.d, x10, x21, vlx2 // 00100101-11110101-01000101-01010101 +// CHECK-INST: whilelt pn13.d, x10, x21, vlx2 +// CHECK-ENCODING: [0x55,0x45,0xf5,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25f54555 + +whilelt pn15.d, x13, x8, vlx4 // 00100101-11101000-01100101-10110111 +// CHECK-INST: whilelt pn15.d, x13, x8, vlx4 +// CHECK-ENCODING: [0xb7,0x65,0xe8,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25e865b7 + +whilelt pn15.d, xzr, xzr, vlx4 // 00100101-11111111-01100111-11110111 +// CHECK-INST: whilelt pn15.d, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xf7,0x67,0xff,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25ff67f7 + +whilelt pn8.b, x0, x0, vlx2 // 00100101-00100000-01000100-00010000 +// CHECK-INST: whilelt pn8.b, x0, x0, vlx2 +// CHECK-ENCODING: [0x10,0x44,0x20,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25204410 + +whilelt pn13.b, x10, x21, vlx2 // 00100101-00110101-01000101-01010101 +// CHECK-INST: whilelt pn13.b, x10, x21, vlx2 +// CHECK-ENCODING: [0x55,0x45,0x35,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 25354555 + +whilelt pn15.b, x13, x8, vlx4 // 00100101-00101000-01100101-10110111 +// CHECK-INST: whilelt pn15.b, x13, x8, vlx4 +// CHECK-ENCODING: [0xb7,0x65,0x28,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 252865b7 + +whilelt pn15.b, xzr, xzr, vlx4 // 00100101-00111111-01100111-11110111 +// CHECK-INST: whilelt pn15.b, xzr, xzr, vlx4 +// CHECK-ENCODING: [0xf7,0x67,0x3f,0x25] +// CHECK-ERROR: instruction requires: sme2 or sve2p1 +// CHECK-UNKNOWN: 253f67f7