99 lines · plain
1// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sve2 < %s \2// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST3// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sme < %s \4// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST5// RUN: not llvm-mc -triple=aarch64 -show-encoding < %s 2>&1 \6// RUN: | FileCheck %s --check-prefix=CHECK-ERROR7// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sve2 < %s \8// RUN: | llvm-objdump -d --mattr=+sve2 - | FileCheck %s --check-prefix=CHECK-INST9// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sve2 < %s \10// RUN: | llvm-objdump -d --mattr=-sve2 - | FileCheck %s --check-prefix=CHECK-UNKNOWN11 12cdot z0.s, z1.b, z31.b, #013// CHECK-INST: cdot z0.s, z1.b, z31.b, #014// CHECK-ENCODING: [0x20,0x10,0x9f,0x44]15// CHECK-ERROR: instruction requires: sve2 or sme16// CHECK-UNKNOWN: 449f1020 <unknown>17 18cdot z0.d, z1.h, z31.h, #019// CHECK-INST: cdot z0.d, z1.h, z31.h, #020// CHECK-ENCODING: [0x20,0x10,0xdf,0x44]21// CHECK-ERROR: instruction requires: sve2 or sme22// CHECK-UNKNOWN: 44df1020 <unknown>23 24cdot z0.d, z1.h, z31.h, #9025// CHECK-INST: cdot z0.d, z1.h, z31.h, #9026// CHECK-ENCODING: [0x20,0x14,0xdf,0x44]27// CHECK-ERROR: instruction requires: sve2 or sme28// CHECK-UNKNOWN: 44df1420 <unknown>29 30cdot z0.d, z1.h, z31.h, #18031// CHECK-INST: cdot z0.d, z1.h, z31.h, #18032// CHECK-ENCODING: [0x20,0x18,0xdf,0x44]33// CHECK-ERROR: instruction requires: sve2 or sme34// CHECK-UNKNOWN: 44df1820 <unknown>35 36cdot z0.d, z1.h, z31.h, #27037// CHECK-INST: cdot z0.d, z1.h, z31.h, #27038// CHECK-ENCODING: [0x20,0x1c,0xdf,0x44]39// CHECK-ERROR: instruction requires: sve2 or sme40// CHECK-UNKNOWN: 44df1c20 <unknown>41 42cdot z0.s, z1.b, z7.b[3], #043// CHECK-INST: cdot z0.s, z1.b, z7.b[3], #044// CHECK-ENCODING: [0x20,0x40,0xbf,0x44]45// CHECK-ERROR: instruction requires: sve2 or sme46// CHECK-UNKNOWN: 44bf4020 <unknown>47 48cdot z0.d, z1.h, z15.h[1], #049// CHECK-INST: cdot z0.d, z1.h, z15.h[1], #050// CHECK-ENCODING: [0x20,0x40,0xff,0x44]51// CHECK-ERROR: instruction requires: sve2 or sme52// CHECK-UNKNOWN: 44ff4020 <unknown>53 54cdot z5.d, z6.h, z3.h[0], #9055// CHECK-INST: cdot z5.d, z6.h, z3.h[0], #9056// CHECK-ENCODING: [0xc5,0x44,0xe3,0x44]57// CHECK-ERROR: instruction requires: sve2 or sme58// CHECK-UNKNOWN: 44e344c5 <unknown>59 60cdot z29.d, z30.h, z0.h[0], #18061// CHECK-INST: cdot z29.d, z30.h, z0.h[0], #18062// CHECK-ENCODING: [0xdd,0x4b,0xe0,0x44]63// CHECK-ERROR: instruction requires: sve2 or sme64// CHECK-UNKNOWN: 44e04bdd <unknown>65 66cdot z31.d, z30.h, z7.h[1], #27067// CHECK-INST: cdot z31.d, z30.h, z7.h[1], #27068// CHECK-ENCODING: [0xdf,0x4f,0xf7,0x44]69// CHECK-ERROR: instruction requires: sve2 or sme70// CHECK-UNKNOWN: 44f74fdf <unknown>71 72 73// --------------------------------------------------------------------------//74// Test compatibility with MOVPRFX instruction.75 76movprfx z0, z777// CHECK-INST: movprfx z0, z778// CHECK-ENCODING: [0xe0,0xbc,0x20,0x04]79// CHECK-ERROR: instruction requires: sve or sme80// CHECK-UNKNOWN: 0420bce0 <unknown>81 82cdot z0.d, z1.h, z31.h, #083// CHECK-INST: cdot z0.d, z1.h, z31.h, #084// CHECK-ENCODING: [0x20,0x10,0xdf,0x44]85// CHECK-ERROR: instruction requires: sve2 or sme86// CHECK-UNKNOWN: 44df1020 <unknown>87 88movprfx z0, z789// CHECK-INST: movprfx z0, z790// CHECK-ENCODING: [0xe0,0xbc,0x20,0x04]91// CHECK-ERROR: instruction requires: sve or sme92// CHECK-UNKNOWN: 0420bce0 <unknown>93 94cdot z0.d, z1.h, z15.h[1], #095// CHECK-INST: cdot z0.d, z1.h, z15.h[1], #096// CHECK-ENCODING: [0x20,0x40,0xff,0x44]97// CHECK-ERROR: instruction requires: sve2 or sme98// CHECK-UNKNOWN: 44ff4020 <unknown>99