1# RUN: not llvm-mc -triple=thumbv8.1m.main-none-eabi -mattr=+mve -show-encoding < %s \ 2# RUN: | FileCheck --check-prefix=CHECK %s 3# RUN: not llvm-mc -triple=thumbv8.1m.main-none-eabi -mattr=+mve.fp,+fp64 -show-encoding < %s 2>%t \ 4# RUN: | FileCheck --check-prefix=CHECK %s 5# RUN: FileCheck --check-prefix=ERROR < %t %s 6# RUN: not llvm-mc -triple=thumbv8.1m.main-none-eabi -show-encoding < %s 2>%t 7# RUN: FileCheck --check-prefix=ERROR-NOMVE < %t %s 8 9# CHECK: vpsel q0, q5, q2 @ encoding: [0x3b,0xfe,0x05,0x0f] 10# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 11vpsel q0, q5, q2 12 13# CHECK: vpnot @ encoding: [0x31,0xfe,0x4d,0x0f] 14# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 15vpnot 16 17# CHECK: wlstp.8 lr, r0, #1668 @ encoding: [0x00,0xf0,0x43,0xc3] 18# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 19wlstp.8 lr, r0, #1668 20 21# CHECK: wlstp.16 lr, r0, #1668 @ encoding: [0x10,0xf0,0x43,0xc3] 22# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 23wlstp.16 lr, r0, #1668 24 25# CHECK: wlstp.32 lr, r4, #2706 @ encoding: [0x24,0xf0,0x49,0xcd] 26# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 27wlstp.32 lr, r4, #2706 28 29# CHECK: wlstp.64 lr, lr, #3026 @ encoding: [0x3e,0xf0,0xe9,0xcd] 30# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 31wlstp.64 lr, lr, #3026 32 33# CHECK: wlstp.8 lr, r5, #3436 @ encoding: [0x05,0xf0,0xb7,0xc6] 34# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 35wlstp.8 lr, r5, #3436 36 37# CHECK: wlstp.16 lr, r1, #1060 @ encoding: [0x11,0xf0,0x13,0xc2] 38# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 39wlstp.16 lr, r1, #1060 40 41# CHECK: wlstp.32 lr, r7, #4036 @ encoding: [0x27,0xf0,0xe3,0xc7] 42# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 43wlstp.32 lr, r7, #4036 44 45# CHECK: wlstp.8 lr, r1, #538 @ encoding: [0x01,0xf0,0x0d,0xc9] 46# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 47wlstp.8 lr, r1, #538 48 49# CHECK: wlstp.8 lr, r10, #1404 @ encoding: [0x0a,0xf0,0xbf,0xc2] 50# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 51wlstp.8 lr, r10, #1404 52 53# CHECK: wlstp.8 lr, r10, #1408 @ encoding: [0x0a,0xf0,0xc1,0xc2] 54# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 55wlstp.8 lr, r10, #1408 56 57# CHECK: wlstp.8 lr, r10, #2358 @ encoding: [0x0a,0xf0,0x9b,0xcc] 58# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 59wlstp.8 lr, r10, #2358 60 61# CHECK: wlstp.8 lr, r10, #4086 @ encoding: [0x0a,0xf0,0xfb,0xcf] 62# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 63wlstp.8 lr, r10, #4086 64 65# CHECK: wlstp.8 lr, r11, #1442 @ encoding: [0x0b,0xf0,0xd1,0xca] 66# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 67wlstp.8 lr, r11, #1442 68 69# ERROR: [[@LINE+2]]:{{[0-9]+}}: {{error|note}}: loop end is out of range or not a positive multiple of 2 70# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 71wlstp.8 lr, r10, #1443 72 73# ERROR: [[@LINE+2]]:{{[0-9]+}}: {{error|note}}: loop end is out of range or not a positive multiple of 2 74# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 75wlstp.8 lr, r10, #4096 76 77# ERROR: [[@LINE+2]]:{{[0-9]+}}: {{error|note}}: operand must be a register in range [r0, r12] or r14 78# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 79wlstp.8 lr, sp, #1442 80 81# ERROR: [[@LINE+2]]:{{[0-9]+}}: {{error|note}}: operand must be a register in range [r0, r12] or r14 82# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 83wlstp.16 lr, sp, #1442 84 85# ERROR: [[@LINE+2]]:{{[0-9]+}}: {{error|note}}: invalid operand for instruction 86# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 87wlstp.32 r10, r11, #1442 88 89# CHECK: wlstp.8 lr, r1, .Lendloop @ encoding: [0x01'A',0xf0'A',0x01'A',0xc0'A'] 90# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 91wlstp.8 lr, r1, .Lendloop 92 93# CHECK: wlstp.16 lr, r2, .Lendloop @ encoding: [0x12'A',0xf0'A',0x01'A',0xc0'A'] 94# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 95wlstp.16 lr, r2, .Lendloop 96 97# CHECK: wlstp.32 lr, r3, .Lendloop @ encoding: [0x23'A',0xf0'A',0x01'A',0xc0'A'] 98# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 99wlstp.32 lr, r3, .Lendloop 100 101# CHECK: wlstp.64 lr, r5, .Lendloop @ encoding: [0x35'A',0xf0'A',0x01'A',0xc0'A'] 102# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 103wlstp.64 lr, r5, .Lendloop 104 105# CHECK: wlstp.64 lr, r5, #0 @ encoding: [0x35,0xf0,0x01,0xc0] 106# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 107wlstp.64 lr, r5, #0 108 109# CHECK: dlstp.8 lr, r5 @ encoding: [0x05,0xf0,0x01,0xe0] 110# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 111dlstp.8 lr, r5 112 113# CHECK: dlstp.16 lr, r5 @ encoding: [0x15,0xf0,0x01,0xe0] 114# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 115dlstp.16 lr, r5 116 117# CHECK: dlstp.32 lr, r7 @ encoding: [0x27,0xf0,0x01,0xe0] 118# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 119dlstp.32 lr, r7 120 121# CHECK: dlstp.64 lr, r2 @ encoding: [0x32,0xf0,0x01,0xe0] 122# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 123dlstp.64 lr, r2 124 125# ERROR: [[@LINE+2]]:{{[0-9]+}}: {{error|note}}: operand must be a register in range [r0, r12] or r14 126# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 127dlstp.64 lr, sp 128 129# ERROR: [[@LINE+2]]:{{[0-9]+}}: {{error|note}}: invalid operand for instruction 130# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 131dlstp.64 r10, r0 132 133# ERROR: [[@LINE+2]]:{{[0-9]+}}: {{error|note}}: operand must be a register in range [r0, r12] or r14 134# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 135dlstp.64 lr, pc 136 137# CHECK: letp lr, #-2 @ encoding: [0x1f,0xf0,0x01,0xc8] 138# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 139letp lr, #-2 140 141# CHECK: letp lr, #-8 @ encoding: [0x1f,0xf0,0x05,0xc0] 142# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 143letp lr, #-8 144 145# CHECK: letp lr, #-4094 @ encoding: [0x1f,0xf0,0xff,0xcf] 146# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 147letp lr, #-4094 148 149# ERROR: [[@LINE+2]]:{{[0-9]+}}: {{error|note}}: invalid operand for instruction 150# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 151letp r0, #-8 152 153# ERROR: [[@LINE+2]]:{{[0-9]+}}: {{error|note}}: loop start is out of range or not a negative multiple of 2 154# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 155letp lr, #8 156 157# ERROR: [[@LINE+2]]:{{[0-9]+}}: {{error|note}}: loop start is out of range or not a negative multiple of 2 158# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 159letp lr, #-4096 160 161# CHECK: letp lr, .Lstartloop @ encoding: [0x1f'A',0xf0'A',0x01'A',0xc0'A'] 162# ERROR-NOMVE: [[@LINE+1]]:1: error: invalid instruction 163letp lr, .Lstartloop 164 165# CHECK: lctp @ encoding: [0x0f,0xf0,0x01,0xe0] 166# ERROR-NOMVE: [[@LINE+1]]:1: error: instruction requires: mve 167lctp 168 169# CHECK: it eq @ encoding: [0x08,0xbf] 170it eq 171# CHECK: lctpeq @ encoding: [0x0f,0xf0,0x01,0xe0] 172# ERROR-NOMVE: [[@LINE+1]]:1: error: instruction requires: mve 173lctpeq 174 175vpste 176vpselt.s16 q0, q1, q2 177vpsele.i32 q0, q1, q2 178# CHECK: vpste @ encoding: [0x71,0xfe,0x4d,0x8f] 179# CHECK: vpselt q0, q1, q2 @ encoding: [0x33,0xfe,0x05,0x0f] 180# CHECK: vpsele q0, q1, q2 @ encoding: [0x33,0xfe,0x05,0x0f] 181