177 lines · plain
1// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sve < %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=+sve < %s \8// RUN: | llvm-objdump -d --mattr=+sve - | FileCheck %s --check-prefix=CHECK-INST9// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sve < %s \10// RUN: | llvm-objdump -d --mattr=-sve - | FileCheck %s --check-prefix=CHECK-UNKNOWN11 12fmul z0.h, p0/m, z0.h, #0.500000000000013// CHECK-INST: fmul z0.h, p0/m, z0.h, #0.514// CHECK-ENCODING: [0x00,0x80,0x5a,0x65]15// CHECK-ERROR: instruction requires: sve or sme16// CHECK-UNKNOWN: 655a8000 <unknown>17 18fmul z0.h, p0/m, z0.h, #0.519// CHECK-INST: fmul z0.h, p0/m, z0.h, #0.520// CHECK-ENCODING: [0x00,0x80,0x5a,0x65]21// CHECK-ERROR: instruction requires: sve or sme22// CHECK-UNKNOWN: 655a8000 <unknown>23 24fmul z0.s, p0/m, z0.s, #0.525// CHECK-INST: fmul z0.s, p0/m, z0.s, #0.526// CHECK-ENCODING: [0x00,0x80,0x9a,0x65]27// CHECK-ERROR: instruction requires: sve or sme28// CHECK-UNKNOWN: 659a8000 <unknown>29 30fmul z0.d, p0/m, z0.d, #0.531// CHECK-INST: fmul z0.d, p0/m, z0.d, #0.532// CHECK-ENCODING: [0x00,0x80,0xda,0x65]33// CHECK-ERROR: instruction requires: sve or sme34// CHECK-UNKNOWN: 65da8000 <unknown>35 36fmul z31.h, p7/m, z31.h, #2.037// CHECK-INST: fmul z31.h, p7/m, z31.h, #2.038// CHECK-ENCODING: [0x3f,0x9c,0x5a,0x65]39// CHECK-ERROR: instruction requires: sve or sme40// CHECK-UNKNOWN: 655a9c3f <unknown>41 42fmul z31.s, p7/m, z31.s, #2.043// CHECK-INST: fmul z31.s, p7/m, z31.s, #2.044// CHECK-ENCODING: [0x3f,0x9c,0x9a,0x65]45// CHECK-ERROR: instruction requires: sve or sme46// CHECK-UNKNOWN: 659a9c3f <unknown>47 48fmul z31.d, p7/m, z31.d, #2.049// CHECK-INST: fmul z31.d, p7/m, z31.d, #2.050// CHECK-ENCODING: [0x3f,0x9c,0xda,0x65]51// CHECK-ERROR: instruction requires: sve or sme52// CHECK-UNKNOWN: 65da9c3f <unknown>53 54fmul z0.h, z0.h, z0.h[0]55// CHECK-INST: fmul z0.h, z0.h, z0.h[0]56// CHECK-ENCODING: [0x00,0x20,0x20,0x64]57// CHECK-ERROR: instruction requires: sve or sme58// CHECK-UNKNOWN: 64202000 <unknown>59 60fmul z0.s, z0.s, z0.s[0]61// CHECK-INST: fmul z0.s, z0.s, z0.s[0]62// CHECK-ENCODING: [0x00,0x20,0xa0,0x64]63// CHECK-ERROR: instruction requires: sve or sme64// CHECK-UNKNOWN: 64a02000 <unknown>65 66fmul z0.d, z0.d, z0.d[0]67// CHECK-INST: fmul z0.d, z0.d, z0.d[0]68// CHECK-ENCODING: [0x00,0x20,0xe0,0x64]69// CHECK-ERROR: instruction requires: sve or sme70// CHECK-UNKNOWN: 64e02000 <unknown>71 72fmul z31.h, z31.h, z7.h[7]73// CHECK-INST: fmul z31.h, z31.h, z7.h[7]74// CHECK-ENCODING: [0xff,0x23,0x7f,0x64]75// CHECK-ERROR: instruction requires: sve or sme76// CHECK-UNKNOWN: 647f23ff <unknown>77 78fmul z31.s, z31.s, z7.s[3]79// CHECK-INST: fmul z31.s, z31.s, z7.s[3]80// CHECK-ENCODING: [0xff,0x23,0xbf,0x64]81// CHECK-ERROR: instruction requires: sve or sme82// CHECK-UNKNOWN: 64bf23ff <unknown>83 84fmul z31.d, z31.d, z15.d[1]85// CHECK-INST: fmul z31.d, z31.d, z15.d[1]86// CHECK-ENCODING: [0xff,0x23,0xff,0x64]87// CHECK-ERROR: instruction requires: sve or sme88// CHECK-UNKNOWN: 64ff23ff <unknown>89 90fmul z0.h, p7/m, z0.h, z31.h91// CHECK-INST: fmul z0.h, p7/m, z0.h, z31.h92// CHECK-ENCODING: [0xe0,0x9f,0x42,0x65]93// CHECK-ERROR: instruction requires: sve or sme94// CHECK-UNKNOWN: 65429fe0 <unknown>95 96fmul z0.s, p7/m, z0.s, z31.s97// CHECK-INST: fmul z0.s, p7/m, z0.s, z31.s98// CHECK-ENCODING: [0xe0,0x9f,0x82,0x65]99// CHECK-ERROR: instruction requires: sve or sme100// CHECK-UNKNOWN: 65829fe0 <unknown>101 102fmul z0.d, p7/m, z0.d, z31.d103// CHECK-INST: fmul z0.d, p7/m, z0.d, z31.d104// CHECK-ENCODING: [0xe0,0x9f,0xc2,0x65]105// CHECK-ERROR: instruction requires: sve or sme106// CHECK-UNKNOWN: 65c29fe0 <unknown>107 108fmul z0.h, z1.h, z31.h109// CHECK-INST: fmul z0.h, z1.h, z31.h110// CHECK-ENCODING: [0x20,0x08,0x5f,0x65]111// CHECK-ERROR: instruction requires: sve or sme112// CHECK-UNKNOWN: 655f0820 <unknown>113 114fmul z0.s, z1.s, z31.s115// CHECK-INST: fmul z0.s, z1.s, z31.s116// CHECK-ENCODING: [0x20,0x08,0x9f,0x65]117// CHECK-ERROR: instruction requires: sve or sme118// CHECK-UNKNOWN: 659f0820 <unknown>119 120fmul z0.d, z1.d, z31.d121// CHECK-INST: fmul z0.d, z1.d, z31.d122// CHECK-ENCODING: [0x20,0x08,0xdf,0x65]123// CHECK-ERROR: instruction requires: sve or sme124// CHECK-UNKNOWN: 65df0820 <unknown>125 126 127// --------------------------------------------------------------------------//128// Test compatibility with MOVPRFX instruction.129 130movprfx z31.d, p7/z, z6.d131// CHECK-INST: movprfx z31.d, p7/z, z6.d132// CHECK-ENCODING: [0xdf,0x3c,0xd0,0x04]133// CHECK-ERROR: instruction requires: sve or sme134// CHECK-UNKNOWN: 04d03cdf <unknown>135 136fmul z31.d, p7/m, z31.d, #2.0137// CHECK-INST: fmul z31.d, p7/m, z31.d, #2.0138// CHECK-ENCODING: [0x3f,0x9c,0xda,0x65]139// CHECK-ERROR: instruction requires: sve or sme140// CHECK-UNKNOWN: 65da9c3f <unknown>141 142movprfx z31, z6143// CHECK-INST: movprfx z31, z6144// CHECK-ENCODING: [0xdf,0xbc,0x20,0x04]145// CHECK-ERROR: instruction requires: sve or sme146// CHECK-UNKNOWN: 0420bcdf <unknown>147 148fmul z31.d, p7/m, z31.d, #2.0149// CHECK-INST: fmul z31.d, p7/m, z31.d, #2.0150// CHECK-ENCODING: [0x3f,0x9c,0xda,0x65]151// CHECK-ERROR: instruction requires: sve or sme152// CHECK-UNKNOWN: 65da9c3f <unknown>153 154movprfx z0.d, p7/z, z7.d155// CHECK-INST: movprfx z0.d, p7/z, z7.d156// CHECK-ENCODING: [0xe0,0x3c,0xd0,0x04]157// CHECK-ERROR: instruction requires: sve or sme158// CHECK-UNKNOWN: 04d03ce0 <unknown>159 160fmul z0.d, p7/m, z0.d, z31.d161// CHECK-INST: fmul z0.d, p7/m, z0.d, z31.d162// CHECK-ENCODING: [0xe0,0x9f,0xc2,0x65]163// CHECK-ERROR: instruction requires: sve or sme164// CHECK-UNKNOWN: 65c29fe0 <unknown>165 166movprfx z0, z7167// CHECK-INST: movprfx z0, z7168// CHECK-ENCODING: [0xe0,0xbc,0x20,0x04]169// CHECK-ERROR: instruction requires: sve or sme170// CHECK-UNKNOWN: 0420bce0 <unknown>171 172fmul z0.d, p7/m, z0.d, z31.d173// CHECK-INST: fmul z0.d, p7/m, z0.d, z31.d174// CHECK-ENCODING: [0xe0,0x9f,0xc2,0x65]175// CHECK-ERROR: instruction requires: sve or sme176// CHECK-UNKNOWN: 65c29fe0 <unknown>177