114 lines · plain
1// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+ssve-fp8dot2,+ssve-fp8dot4 < %s \2// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST3 4// RUN: not llvm-mc -triple=aarch64 -show-encoding < %s 2>&1 \5// RUN: | FileCheck %s --check-prefix=CHECK-ERROR6 7// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sve2,+fp8dot2,+fp8dot4 < %s \8// RUN: | llvm-objdump -d --mattr=+sve2,+fp8dot2,+fp8dot4 --no-print-imm-hex - | FileCheck %s --check-prefix=CHECK-INST9 10// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sve2,+fp8dot2,+fp8dot4 < %s \11// RUN: | llvm-objdump -d --mattr=-sme2 --no-print-imm-hex - | FileCheck %s --check-prefix=CHECK-UNKNOWN12 13// Disassemble encoding and check the re-encoding (-show-encoding) matches.14// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sve2,+fp8dot2,fp8dot4 < %s \15// RUN: | sed '/.text/d' | sed 's/.*encoding: //g' \16// RUN: | llvm-mc -triple=aarch64 -mattr=+sve2,+fp8dot2,fp8dot4 -disassemble -show-encoding \17// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST18 19//20// FDOT2 instructions21//22// fdot2 - indexed23 24fdot z0.h, z0.b, z0.b[0] // 01100100-00100000-01000100-0000000025// CHECK-INST: fdot z0.h, z0.b, z0.b[0]26// CHECK-ENCODING: [0x00,0x44,0x20,0x64]27// CHECK-ERROR: instruction requires: ssve-fp8dot2 or (sve2 and fp8dot2)28// CHECK-UNKNOWN: 64204400 <unknown>29 30movprfx z23, z3131fdot z23.h, z13.b, z0.b[3] // 01100100-00101000-01001101-1011011132// CHECK-INST: movprfx z23, z3133// CHECK-INST: fdot z23.h, z13.b, z0.b[3]34// CHECK-ENCODING: [0xb7,0x4d,0x28,0x64]35// CHECK-ERROR: instruction requires: ssve-fp8dot2 or (sve2 and fp8dot2)36// CHECK-UNKNOWN: 64284db7 <unknown>37 38fdot z31.h, z31.b, z7.b[7] // 01100100-00111111-01001111-1111111139// CHECK-INST: fdot z31.h, z31.b, z7.b[7]40// CHECK-ENCODING: [0xff,0x4f,0x3f,0x64]41// CHECK-ERROR: instruction requires: ssve-fp8dot2 or (sve2 and fp8dot2)42// CHECK-UNKNOWN: 643f4fff <unknown>43 44 45// fdot2 - group46 47fdot z0.h, z0.b, z0.b // 01100100-00100000-10000100-0000000048// CHECK-INST: fdot z0.h, z0.b, z0.b49// CHECK-ENCODING: [0x00,0x84,0x20,0x64]50// CHECK-ERROR: instruction requires: ssve-fp8dot2 or (sve2 and fp8dot2)51// CHECK-UNKNOWN: 64208400 <unknown>52 53movprfx z23, z3154fdot z23.h, z13.b, z8.b // 01100100-00101000-10000101-1011011155// CHECK-INST: movprfx z23, z3156// CHECK-INST: fdot z23.h, z13.b, z8.b57// CHECK-ENCODING: [0xb7,0x85,0x28,0x64]58// CHECK-ERROR: instruction requires: ssve-fp8dot2 or (sve2 and fp8dot2)59// CHECK-UNKNOWN: 642885b7 <unknown>60 61fdot z31.h, z31.b, z31.b // 01100100-00111111-10000111-1111111162// CHECK-INST: fdot z31.h, z31.b, z31.b63// CHECK-ENCODING: [0xff,0x87,0x3f,0x64]64// CHECK-ERROR: instruction requires: ssve-fp8dot2 or (sve2 and fp8dot2)65// CHECK-UNKNOWN: 643f87ff <unknown>66 67 68//69// FDOT4 instructions70//71// fdot4 - indexed72 73fdot z0.s, z0.b, z0.b[0] // 01100100-01100000-01000100-0000000074// CHECK-INST: fdot z0.s, z0.b, z0.b[0]75// CHECK-ENCODING: [0x00,0x44,0x60,0x64]76// CHECK-ERROR: instruction requires: ssve-fp8dot4 or (sve2 and fp8dot4)77// CHECK-UNKNOWN: 64604400 <unknown>78 79movprfx z23, z3180fdot z23.s, z13.b, z0.b[1] // 01100100-01101000-01000101-1011011181// CHECK-INST: movprfx z23, z3182// CHECK-INST: fdot z23.s, z13.b, z0.b[1]83// CHECK-ENCODING: [0xb7,0x45,0x68,0x64]84// CHECK-ERROR: instruction requires: ssve-fp8dot4 or (sve2 and fp8dot4)85// CHECK-UNKNOWN: 646845b7 <unknown>86 87fdot z31.s, z31.b, z7.b[3] // 01100100-01111111-01000111-1111111188// CHECK-INST: fdot z31.s, z31.b, z7.b[3]89// CHECK-ENCODING: [0xff,0x47,0x7f,0x64]90// CHECK-ERROR: instruction requires: ssve-fp8dot4 or (sve2 and fp8dot4)91// CHECK-UNKNOWN: 647f47ff <unknown>92 93// fdot4 - group94 95fdot z0.s, z0.b, z0.b // 01100100-01100000-10000100-0000000096// CHECK-INST: fdot z0.s, z0.b, z0.b97// CHECK-ENCODING: [0x00,0x84,0x60,0x64]98// CHECK-ERROR: instruction requires: ssve-fp8dot4 or (sve2 and fp8dot4)99// CHECK-UNKNOWN: 64608400 <unknown>100 101movprfx z23, z31102fdot z23.s, z13.b, z8.b // 01100100-01101000-10000101-10110111103// CHECK-INST: movprfx z23, z31104// CHECK-INST: fdot z23.s, z13.b, z8.b105// CHECK-ENCODING: [0xb7,0x85,0x68,0x64]106// CHECK-ERROR: instruction requires: ssve-fp8dot4 or (sve2 and fp8dot4)107// CHECK-UNKNOWN: 646885b7 <unknown>108 109fdot z31.s, z31.b, z31.b // 01100100-01111111-10000111-11111111110// CHECK-INST: fdot z31.s, z31.b, z31.b111// CHECK-ENCODING: [0xff,0x87,0x7f,0x64]112// CHECK-ERROR: instruction requires: ssve-fp8dot4 or (sve2 and fp8dot4)113// CHECK-UNKNOWN: 647f87ff <unknown>114