1// RUN: llvm-mc -triple arm -mattr=+dotprod -show-encoding < %s | FileCheck %s  --check-prefix=CHECK
2// RUN: llvm-mc -triple arm -mcpu=cortex-a55 -show-encoding < %s | FileCheck %s  --check-prefix=CHECK
3// RUN: llvm-mc -triple arm -mcpu=cortex-a75 -show-encoding < %s | FileCheck %s  --check-prefix=CHECK
4// RUN: llvm-mc -triple arm -mcpu=cortex-a76 -show-encoding < %s | FileCheck %s  --check-prefix=CHECK
5// RUN: llvm-mc -triple arm -mcpu=neoverse-n1 -show-encoding < %s | FileCheck %s --check-prefix=CHECK
6// RUN: llvm-mc -triple arm -mcpu=neoverse-n2 -show-encoding < %s | FileCheck %s --check-prefix=CHECK
7// RUN: llvm-mc -triple arm -mcpu=cortex-a77 -show-encoding < %s | FileCheck %s --check-prefix=CHECK
8// RUN: llvm-mc -triple arm -mcpu=cortex-a78 -show-encoding < %s | FileCheck %s --check-prefix=CHECK
9// RUN: llvm-mc -triple arm -mcpu=cortex-x1 -show-encoding < %s | FileCheck %s --check-prefix=CHECK
10
11// RUN: not llvm-mc -triple arm -mattr=-dotprod -show-encoding < %s 2> %t
12// RUN: FileCheck --check-prefix=CHECK-NO-DOTPROD < %t %s
13// RUN: not llvm-mc -triple arm -mcpu=cortex-a77 -mattr=-dotprod -show-encoding < %s 2> %t
14// RUN: FileCheck --check-prefix=CHECK-NO-DOTPROD < %t %s
15// RUN: not llvm-mc -triple arm -mcpu=cortex-a78 -mattr=-dotprod -show-encoding < %s 2> %t
16// RUN: FileCheck --check-prefix=CHECK-NO-DOTPROD < %t %s
17// RUN: not llvm-mc -triple arm -mcpu=cortex-x1 -mattr=-dotprod -show-encoding < %s 2> %t
18// RUN: FileCheck --check-prefix=CHECK-NO-DOTPROD < %t %s
19// RUN: not llvm-mc -triple arm -show-encoding < %s 2> %t
20// RUN: FileCheck --check-prefix=CHECK-NO-DOTPROD < %t %s
21// RUN: not llvm-mc -triple arm -mattr=+v8.1a -show-encoding < %s 2> %t
22// RUN: FileCheck --check-prefix=CHECK-NO-DOTPROD < %t %s
23// RUN: not llvm-mc -triple arm -mattr=+v8.2a -show-encoding < %s 2> %t
24// RUN: FileCheck --check-prefix=CHECK-NO-DOTPROD < %t %s
25
26vudot.u8 d0, d1, d2
27vsdot.s8 d0, d1, d2
28vudot.u8 q0, q1, q4
29vsdot.s8 q0, q1, q4
30vudot.u8 d0, d1, d2[0]
31vsdot.s8 d0, d1, d2[1]
32vudot.u8 q0, q1, d4[0]
33vsdot.s8 q0, q1, d4[1]
34
35// CHECK: vudot.u8  d0, d1, d2      @ encoding: [0x12,0x0d,0x21,0xfc]
36// CHECK: vsdot.s8  d0, d1, d2      @ encoding: [0x02,0x0d,0x21,0xfc]
37// CHECK: vudot.u8  q0, q1, q4      @ encoding: [0x58,0x0d,0x22,0xfc]
38// CHECK: vsdot.s8  q0, q1, q4      @ encoding: [0x48,0x0d,0x22,0xfc]
39// CHECK: vudot.u8  d0, d1, d2[0]   @ encoding: [0x12,0x0d,0x21,0xfe]
40// CHECK: vsdot.s8  d0, d1, d2[1]   @ encoding: [0x22,0x0d,0x21,0xfe]
41// CHECK: vudot.u8  q0, q1, d4[0]   @ encoding: [0x54,0x0d,0x22,0xfe]
42// CHECK: vsdot.s8  q0, q1, d4[1]   @ encoding: [0x64,0x0d,0x22,0xfe]
43
44// CHECK-NO-DOTPROD: error: instruction requires: dotprod
45// CHECK-NO-DOTPROD: error: instruction requires: dotprod
46// CHECK-NO-DOTPROD: error: instruction requires: dotprod
47// CHECK-NO-DOTPROD: error: instruction requires: dotprod
48// CHECK-NO-DOTPROD: error: instruction requires: dotprod
49// CHECK-NO-DOTPROD: error: instruction requires: dotprod
50// CHECK-NO-DOTPROD: error: instruction requires: dotprod
51// CHECK-NO-DOTPROD: error: instruction requires: dotprod
52