1// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sve < %s \ 2// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST 3// RUN: not llvm-mc -triple=aarch64 -show-encoding < %s 2>&1 \ 4// RUN: | FileCheck %s --check-prefix=CHECK-ERROR 5// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sve < %s \ 6// RUN: | llvm-objdump -d --mattr=+sve - | FileCheck %s --check-prefix=CHECK-INST 7// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sve < %s \ 8// RUN: | llvm-objdump -d - | FileCheck %s --check-prefix=CHECK-UNKNOWN 9 10adr z0.s, [z0.s, z0.s] 11// CHECK-INST: adr z0.s, [z0.s, z0.s] 12// CHECK-ENCODING: [0x00,0xa0,0xa0,0x04] 13// CHECK-ERROR: instruction requires: sve 14// CHECK-UNKNOWN: 00 a0 a0 04 <unknown> 15 16adr z0.s, [z0.s, z0.s, lsl #0] 17// CHECK-INST: adr z0.s, [z0.s, z0.s] 18// CHECK-ENCODING: [0x00,0xa0,0xa0,0x04] 19// CHECK-ERROR: instruction requires: sve 20// CHECK-UNKNOWN: 00 a0 a0 04 <unknown> 21 22adr z0.s, [z0.s, z0.s, lsl #1] 23// CHECK-INST: adr z0.s, [z0.s, z0.s, lsl #1] 24// CHECK-ENCODING: [0x00,0xa4,0xa0,0x04] 25// CHECK-ERROR: instruction requires: sve 26// CHECK-UNKNOWN: 00 a4 a0 04 <unknown> 27 28adr z0.s, [z0.s, z0.s, lsl #2] 29// CHECK-INST: adr z0.s, [z0.s, z0.s, lsl #2] 30// CHECK-ENCODING: [0x00,0xa8,0xa0,0x04] 31// CHECK-ERROR: instruction requires: sve 32// CHECK-UNKNOWN: 00 a8 a0 04 <unknown> 33 34adr z0.s, [z0.s, z0.s, lsl #3] 35// CHECK-INST: adr z0.s, [z0.s, z0.s, lsl #3] 36// CHECK-ENCODING: [0x00,0xac,0xa0,0x04] 37// CHECK-ERROR: instruction requires: sve 38// CHECK-UNKNOWN: 00 ac a0 04 <unknown> 39 40adr z0.d, [z0.d, z0.d] 41// CHECK-INST: adr z0.d, [z0.d, z0.d] 42// CHECK-ENCODING: [0x00,0xa0,0xe0,0x04] 43// CHECK-ERROR: instruction requires: sve 44// CHECK-UNKNOWN: 00 a0 e0 04 <unknown> 45 46adr z0.d, [z0.d, z0.d, lsl #0] 47// CHECK-INST: adr z0.d, [z0.d, z0.d] 48// CHECK-ENCODING: [0x00,0xa0,0xe0,0x04] 49// CHECK-ERROR: instruction requires: sve 50// CHECK-UNKNOWN: 00 a0 e0 04 <unknown> 51 52adr z0.d, [z0.d, z0.d, lsl #1] 53// CHECK-INST: adr z0.d, [z0.d, z0.d, lsl #1] 54// CHECK-ENCODING: [0x00,0xa4,0xe0,0x04] 55// CHECK-ERROR: instruction requires: sve 56// CHECK-UNKNOWN: 00 a4 e0 04 <unknown> 57 58adr z0.d, [z0.d, z0.d, lsl #2] 59// CHECK-INST: adr z0.d, [z0.d, z0.d, lsl #2] 60// CHECK-ENCODING: [0x00,0xa8,0xe0,0x04] 61// CHECK-ERROR: instruction requires: sve 62// CHECK-UNKNOWN: 00 a8 e0 04 <unknown> 63 64adr z0.d, [z0.d, z0.d, lsl #3] 65// CHECK-INST: adr z0.d, [z0.d, z0.d, lsl #3] 66// CHECK-ENCODING: [0x00,0xac,0xe0,0x04] 67// CHECK-ERROR: instruction requires: sve 68// CHECK-UNKNOWN: 00 ac e0 04 <unknown> 69 70adr z0.d, [z0.d, z0.d, uxtw] 71// CHECK-INST: adr z0.d, [z0.d, z0.d, uxtw] 72// CHECK-ENCODING: [0x00,0xa0,0x60,0x04] 73// CHECK-ERROR: instruction requires: sve 74// CHECK-UNKNOWN: 00 a0 60 04 <unknown> 75 76adr z0.d, [z0.d, z0.d, uxtw #0] 77// CHECK-INST: adr z0.d, [z0.d, z0.d, uxtw] 78// CHECK-ENCODING: [0x00,0xa0,0x60,0x04] 79// CHECK-ERROR: instruction requires: sve 80// CHECK-UNKNOWN: 00 a0 60 04 <unknown> 81 82adr z0.d, [z0.d, z0.d, uxtw #1] 83// CHECK-INST: adr z0.d, [z0.d, z0.d, uxtw #1] 84// CHECK-ENCODING: [0x00,0xa4,0x60,0x04] 85// CHECK-ERROR: instruction requires: sve 86// CHECK-UNKNOWN: 00 a4 60 04 <unknown> 87 88adr z0.d, [z0.d, z0.d, uxtw #2] 89// CHECK-INST: adr z0.d, [z0.d, z0.d, uxtw #2] 90// CHECK-ENCODING: [0x00,0xa8,0x60,0x04] 91// CHECK-ERROR: instruction requires: sve 92// CHECK-UNKNOWN: 00 a8 60 04 <unknown> 93 94adr z0.d, [z0.d, z0.d, uxtw #3] 95// CHECK-INST: adr z0.d, [z0.d, z0.d, uxtw #3] 96// CHECK-ENCODING: [0x00,0xac,0x60,0x04] 97// CHECK-ERROR: instruction requires: sve 98// CHECK-UNKNOWN: 00 ac 60 04 <unknown> 99 100adr z0.d, [z0.d, z0.d, sxtw] 101// CHECK-INST: adr z0.d, [z0.d, z0.d, sxtw] 102// CHECK-ENCODING: [0x00,0xa0,0x20,0x04] 103// CHECK-ERROR: instruction requires: sve 104// CHECK-UNKNOWN: 00 a0 20 04 <unknown> 105 106adr z0.d, [z0.d, z0.d, sxtw #0] 107// CHECK-INST: adr z0.d, [z0.d, z0.d, sxtw] 108// CHECK-ENCODING: [0x00,0xa0,0x20,0x04] 109// CHECK-ERROR: instruction requires: sve 110// CHECK-UNKNOWN: 00 a0 20 04 <unknown> 111 112adr z0.d, [z0.d, z0.d, sxtw #1] 113// CHECK-INST: adr z0.d, [z0.d, z0.d, sxtw #1] 114// CHECK-ENCODING: [0x00,0xa4,0x20,0x04] 115// CHECK-ERROR: instruction requires: sve 116// CHECK-UNKNOWN: 00 a4 20 04 <unknown> 117 118adr z0.d, [z0.d, z0.d, sxtw #2] 119// CHECK-INST: adr z0.d, [z0.d, z0.d, sxtw #2] 120// CHECK-ENCODING: [0x00,0xa8,0x20,0x04] 121// CHECK-ERROR: instruction requires: sve 122// CHECK-UNKNOWN: 00 a8 20 04 <unknown> 123 124adr z0.d, [z0.d, z0.d, sxtw #3] 125// CHECK-INST: adr z0.d, [z0.d, z0.d, sxtw #3] 126// CHECK-ENCODING: [0x00,0xac,0x20,0x04] 127// CHECK-ERROR: instruction requires: sve 128// CHECK-UNKNOWN: 00 ac 20 04 <unknown> 129