1# RUN: llvm-mc -triple=riscv64 -show-encoding --mattr=+experimental-v %s \ 2# RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST 3# RUN: not llvm-mc -triple=riscv64 -show-encoding %s 2>&1 \ 4# RUN: | FileCheck %s --check-prefix=CHECK-ERROR 5# RUN: llvm-mc -triple=riscv64 -filetype=obj --mattr=+experimental-v %s \ 6# RUN: | llvm-objdump -d --mattr=+experimental-v - \ 7# RUN: | FileCheck %s --check-prefix=CHECK-INST 8# RUN: llvm-mc -triple=riscv64 -filetype=obj --mattr=+experimental-v %s \ 9# RUN: | llvm-objdump -d - | FileCheck %s --check-prefix=CHECK-UNKNOWN 10 11vsetvli a2, a0, e32,m1,ta,ma 12# CHECK-INST: vsetvli a2, a0, e32,m1,ta,ma 13# CHECK-ENCODING: [0x57,0x76,0x85,0x0c] 14# CHECK-ERROR: instruction requires the following: 'V' (Vector Instructions) 15# CHECK-UNKNOWN: 57 76 85 0c <unknown> 16 17vsetvli a2, a0, e32,m2,ta,ma 18# CHECK-INST: vsetvli a2, a0, e32,m2,ta,ma 19# CHECK-ENCODING: [0x57,0x76,0x95,0x0c] 20# CHECK-ERROR: instruction requires the following: 'V' (Vector Instructions) 21# CHECK-UNKNOWN: 57 76 95 0c <unknown> 22 23vsetvli a2, a0, e32,m4,ta,ma 24# CHECK-INST: vsetvli a2, a0, e32,m4,ta,ma 25# CHECK-ENCODING: [0x57,0x76,0xa5,0x0c] 26# CHECK-ERROR: instruction requires the following: 'V' (Vector Instructions) 27# CHECK-UNKNOWN: 57 76 a5 0c <unknown> 28 29vsetvli a2, a0, e32,m8,ta,ma 30# CHECK-INST: vsetvli a2, a0, e32,m8,ta,ma 31# CHECK-ENCODING: [0x57,0x76,0xb5,0x0c] 32# CHECK-ERROR: instruction requires the following: 'V' (Vector Instructions) 33# CHECK-UNKNOWN: 57 76 b5 0c <unknown> 34 35vsetvli a2, a0, e32,mf2,ta,ma 36# CHECK-INST: vsetvli a2, a0, e32,mf2,ta,ma 37# CHECK-ENCODING: [0x57,0x76,0xb5,0x0e] 38# CHECK-ERROR: instruction requires the following: 'V' (Vector Instructions) 39# CHECK-UNKNOWN: 57 76 b5 0e <unknown> 40 41vsetvli a2, a0, e32,mf4,ta,ma 42# CHECK-INST: vsetvli a2, a0, e32,mf4,ta,ma 43# CHECK-ENCODING: [0x57,0x76,0xa5,0x0e] 44# CHECK-ERROR: instruction requires the following: 'V' (Vector Instructions) 45# CHECK-UNKNOWN: 57 76 a5 0e <unknown> 46 47vsetvli a2, a0, e32,mf8,ta,ma 48# CHECK-INST: vsetvli a2, a0, e32,mf8,ta,ma 49# CHECK-ENCODING: [0x57,0x76,0x95,0x0e] 50# CHECK-ERROR: instruction requires the following: 'V' (Vector Instructions) 51# CHECK-UNKNOWN: 57 76 95 0e <unknown> 52 53vsetvli a2, a0, e32,m1,ta,ma 54# CHECK-INST: vsetvli a2, a0, e32,m1,ta,ma 55# CHECK-ENCODING: [0x57,0x76,0x85,0x0c] 56# CHECK-ERROR: instruction requires the following: 'V' (Vector Instructions) 57# CHECK-UNKNOWN: 57 76 85 0c <unknown> 58 59vsetvli a2, a0, e32,m1,tu,ma 60# CHECK-INST: vsetvli a2, a0, e32,m1,tu,ma 61# CHECK-ENCODING: [0x57,0x76,0x85,0x08] 62# CHECK-ERROR: instruction requires the following: 'V' (Vector Instructions) 63# CHECK-UNKNOWN: 57 76 85 08 <unknown> 64 65vsetvli a2, a0, e32,m1,ta,mu 66# CHECK-INST: vsetvli a2, a0, e32,m1,ta,mu 67# CHECK-ENCODING: [0x57,0x76,0x85,0x04] 68# CHECK-ERROR: instruction requires the following: 'V' (Vector Instructions) 69# CHECK-UNKNOWN: 57 76 85 04 <unknown> 70 71vsetvli a2, a0, e32,m1,tu,mu 72# CHECK-INST: vsetvli a2, a0, e32,m1 73# CHECK-ENCODING: [0x57,0x76,0x85,0x00] 74# CHECK-ERROR: instruction requires the following: 'V' (Vector Instructions) 75# CHECK-UNKNOWN: 57 76 85 00 <unknown> 76 77vsetvl a2, a0, a1 78# CHECK-INST: vsetvl a2, a0, a1 79# CHECK-ENCODING: [0x57,0x76,0xb5,0x80] 80# CHECK-ERROR: instruction requires the following: 'V' (Vector Instructions) 81# CHECK-UNKNOWN: 57 76 b5 80 <unknown> 82