1// RUN: llvm-mc -triple aarch64 -show-encoding -mattr=+bf16 < %s | FileCheck %s 2// RUN: llvm-mc -triple aarch64 -show-encoding -mattr=+v8.6a < %s | FileCheck %s 3// RUN: not llvm-mc -triple aarch64 -show-encoding -mattr=-bf16 < %s 2>&1 | FileCheck %s --check-prefix=NOBF16 4// RUN: not llvm-mc -triple aarch64 -show-encoding < %s 2>&1 | FileCheck %s --check-prefix=NOBF16 5 6 7bfdot v2.2s, v3.4h, v4.4h 8bfdot v2.4s, v3.8h, v4.8h 9// CHECK: bfdot v2.2s, v3.4h, v4.4h // encoding: [0x62,0xfc,0x44,0x2e] 10// CHECK: bfdot v2.4s, v3.8h, v4.8h // encoding: [0x62,0xfc,0x44,0x6e] 11// NOBF16: instruction requires: bf16 12// NOBF16-NEXT: bfdot v2.2s, v3.4h, v4.4h 13// NOBF16: instruction requires: bf16 14// NOBF16-NEXT: bfdot v2.4s, v3.8h, v4.8h 15 16bfdot v2.2s, v3.4h, v4.2h[0] 17bfdot v2.2s, v3.4h, v4.2h[1] 18bfdot v2.2s, v3.4h, v4.2h[2] 19bfdot v2.2s, v3.4h, v4.2h[3] 20// CHECK: bfdot v2.2s, v3.4h, v4.2h[0] // encoding: [0x62,0xf0,0x44,0x0f] 21// CHECK: bfdot v2.2s, v3.4h, v4.2h[1] // encoding: [0x62,0xf0,0x64,0x0f] 22// CHECK: bfdot v2.2s, v3.4h, v4.2h[2] // encoding: [0x62,0xf8,0x44,0x0f] 23// CHECK: bfdot v2.2s, v3.4h, v4.2h[3] // encoding: [0x62,0xf8,0x64,0x0f] 24// NOBF16: instruction requires: bf16 25// NOBF16-NEXT: bfdot v2.2s, v3.4h, v4.2h[0] 26// NOBF16: instruction requires: bf16 27// NOBF16-NEXT: bfdot v2.2s, v3.4h, v4.2h[1] 28// NOBF16: instruction requires: bf16 29// NOBF16-NEXT: bfdot v2.2s, v3.4h, v4.2h[2] 30// NOBF16: instruction requires: bf16 31// NOBF16-NEXT: bfdot v2.2s, v3.4h, v4.2h[3] 32 33 34bfdot v2.4s, v3.8h, v4.2h[0] 35bfdot v2.4s, v3.8h, v4.2h[1] 36bfdot v2.4s, v3.8h, v4.2h[2] 37bfdot v2.4s, v3.8h, v4.2h[3] 38// CHECK: bfdot v2.4s, v3.8h, v4.2h[0] // encoding: [0x62,0xf0,0x44,0x4f] 39// CHECK: bfdot v2.4s, v3.8h, v4.2h[1] // encoding: [0x62,0xf0,0x64,0x4f] 40// CHECK: bfdot v2.4s, v3.8h, v4.2h[2] // encoding: [0x62,0xf8,0x44,0x4f] 41// CHECK: bfdot v2.4s, v3.8h, v4.2h[3] // encoding: [0x62,0xf8,0x64,0x4f] 42// NOBF16: instruction requires: bf16 43// NOBF16-NEXT: bfdot v2.4s, v3.8h, v4.2h[0] 44// NOBF16: instruction requires: bf16 45// NOBF16-NEXT: bfdot v2.4s, v3.8h, v4.2h[1] 46// NOBF16: instruction requires: bf16 47// NOBF16-NEXT: bfdot v2.4s, v3.8h, v4.2h[2] 48// NOBF16: instruction requires: bf16 49// NOBF16-NEXT: bfdot v2.4s, v3.8h, v4.2h[3] 50 51 52bfmmla v2.4s, v3.8h, v4.8h 53bfmmla v3.4s, v4.8h, v5.8h 54// CHECK: bfmmla v2.4s, v3.8h, v4.8h // encoding: [0x62,0xec,0x44,0x6e] 55// CHECK: bfmmla v3.4s, v4.8h, v5.8h // encoding: [0x83,0xec,0x45,0x6e] 56// NOBF16: instruction requires: bf16 57// NOBF16-NEXT: bfmmla v2.4s, v3.8h, v4.8h 58// NOBF16: instruction requires: bf16 59// NOBF16-NEXT: bfmmla v3.4s, v4.8h, v5.8h 60 61bfcvtn v5.4h, v5.4s 62bfcvtn2 v5.8h, v5.4s 63// CHECK: bfcvtn v5.4h, v5.4s // encoding: [0xa5,0x68,0xa1,0x0e] 64// CHECK: bfcvtn2 v5.8h, v5.4s // encoding: [0xa5,0x68,0xa1,0x4e] 65// NOBF16: instruction requires: bf16 66// NOBF16-NEXT: bfcvtn v5.4h, v5.4s 67// NOBF16: instruction requires: bf16 68// NOBF16-NEXT: bfcvtn2 v5.8h, v5.4s 69 70bfcvt h5, s3 71// CHECK: bfcvt h5, s3 // encoding: [0x65,0x40,0x63,0x1e] 72// NOBF16: instruction requires: bf16 73// NOBF16-NEXT: bfcvt h5, s3 74 75bfmlalb V10.4S, V21.8h, V14.8H 76bfmlalt V21.4S, V14.8h, V10.8H 77// CHECK: bfmlalb v10.4s, v21.8h, v14.8h // encoding: [0xaa,0xfe,0xce,0x2e] 78// CHECK-NEXT: bfmlalt v21.4s, v14.8h, v10.8h // encoding: [0xd5,0xfd,0xca,0x6e] 79// NOBF16: error: instruction requires: bf16 80// NOBF16-NEXT: bfmlalb V10.4S, V21.8h, V14.8H 81// NOBF16-NEXT: ^ 82// NOBF16: instruction requires: bf16 83// NOBF16-NEXT: bfmlalt V21.4S, V14.8h, V10.8H 84// NOBF16-NEXT: ^ 85 86bfmlalb V14.4S, V21.8H, V10.H[1] 87bfmlalb V14.4S, V21.8H, V10.H[2] 88bfmlalb V14.4S, V21.8H, V10.H[7] 89bfmlalt V21.4S, V10.8H, V14.H[1] 90bfmlalt V21.4S, V10.8H, V14.H[2] 91bfmlalt V21.4S, V10.8H, V14.H[7] 92// CHECK: bfmlalb v14.4s, v21.8h, v10.h[1] // encoding: [0xae,0xf2,0xda,0x0f] 93// CHECK-NEXT: bfmlalb v14.4s, v21.8h, v10.h[2] // encoding: [0xae,0xf2,0xea,0x0f] 94// CHECK-NEXT: bfmlalb v14.4s, v21.8h, v10.h[7] // encoding: [0xae,0xfa,0xfa,0x0f] 95// CHECK-NEXT: bfmlalt v21.4s, v10.8h, v14.h[1] // encoding: [0x55,0xf1,0xde,0x4f] 96// CHECK-NEXT: bfmlalt v21.4s, v10.8h, v14.h[2] // encoding: [0x55,0xf1,0xee,0x4f] 97// CHECK-NEXT: bfmlalt v21.4s, v10.8h, v14.h[7] // encoding: [0x55,0xf9,0xfe,0x4f] 98// NOBF16: error: instruction requires: bf16 99// NOBF16-NEXT: bfmlalb V14.4S, V21.8H, V10.H[1] 100// NOBF16-NEXT: ^ 101// NOBF16: error: instruction requires: bf16 102// NOBF16-NEXT: bfmlalb V14.4S, V21.8H, V10.H[2] 103// NOBF16-NEXT: ^ 104// NOBF16: error: instruction requires: bf16 105// NOBF16-NEXT: bfmlalb V14.4S, V21.8H, V10.H[7] 106// NOBF16-NEXT: ^ 107// NOBF16: instruction requires: bf16 108// NOBF16-NEXT: bfmlalt V21.4S, V10.8H, V14.H[1] 109// NOBF16-NEXT: ^ 110// NOBF16: instruction requires: bf16 111// NOBF16-NEXT: bfmlalt V21.4S, V10.8H, V14.H[2] 112// NOBF16-NEXT: ^ 113// NOBF16: instruction requires: bf16 114// NOBF16-NEXT: bfmlalt V21.4S, V10.8H, V14.H[7] 115// NOBF16-NEXT: ^ 116