283 lines · plain
1// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+d128,+the,+el2vmsa,+vh < %s \2// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST3// RUN: not llvm-mc -triple=aarch64 -mattr=+the,+el2vmsa,+vh -show-encoding < %s 2>&1 \4// RUN: | FileCheck %s --check-prefixes=CHECK-ERROR5// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+d128,+the,+el2vmsa,+vh < %s \6// RUN: | llvm-objdump -d --mattr=+d128,+the,+el2vmsa,+vh - | FileCheck %s --check-prefix=CHECK-INST7// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+d128,+the,+el2vmsa,+vh < %s \8// RUN: | llvm-objdump -d --mattr=-d128,+the,+el2vmsa,+vh - | FileCheck %s --check-prefix=CHECK-UNKNOWN9// Disassemble encoding and check the re-encoding (-show-encoding) matches.10// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+d128,+the,+el2vmsa,+vh < %s \11// RUN: | sed '/.text/d' | sed 's/.*encoding: //g' \12// RUN: | llvm-mc -triple=aarch64 -mattr=+d128,+the,+el2vmsa,+vh -disassemble -show-encoding \13// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST14 15 16// +the required for RCWSMASK_EL1, RCWMASK_EL117// +el2vmsa required for TTBR0_EL2 (VSCTLR_EL2), VTTBR_EL218// +vh required for TTBR1_EL219 20mrrs x0, x1, TTBR0_EL121// CHECK-INST: mrrs x0, x1, TTBR0_EL122// CHECK-ENCODING: encoding: [0x00,0x20,0x78,0xd5]23// CHECK-ERROR: error: instruction requires: d12824// CHECK-UNKNOWN: d5782000 <unknown>25 26mrrs x0, x1, TTBR1_EL127// CHECK-INST: mrrs x0, x1, TTBR1_EL128// CHECK-ENCODING: encoding: [0x20,0x20,0x78,0xd5]29// CHECK-ERROR: error: instruction requires: d12830// CHECK-UNKNOWN: d5782020 <unknown>31 32mrrs x0, x1, PAR_EL133// CHECK-INST: mrrs x0, x1, PAR_EL134// CHECK-ENCODING: encoding: [0x00,0x74,0x78,0xd5]35// CHECK-ERROR: error: instruction requires: d12836// CHECK-UNKNOWN: d5787400 <unknown>37 38mrrs x0, x1, RCWSMASK_EL139// CHECK-INST: mrrs x0, x1, RCWSMASK_EL140// CHECK-ENCODING: encoding: [0x60,0xd0,0x78,0xd5]41// CHECK-ERROR: error: instruction requires: d12842// CHECK-UNKNOWN: d578d060 <unknown>43 44mrrs x0, x1, RCWMASK_EL145// CHECK-INST: mrrs x0, x1, RCWMASK_EL146// CHECK-ENCODING: encoding: [0xc0,0xd0,0x78,0xd5]47// CHECK-ERROR: error: instruction requires: d12848// CHECK-UNKNOWN: d578d0c0 <unknown>49 50mrrs x0, x1, TTBR0_EL251// CHECK-INST: mrrs x0, x1, TTBR0_EL252// CHECK-ENCODING: encoding: [0x00,0x20,0x7c,0xd5]53// CHECK-ERROR: error: instruction requires: d12854// CHECK-UNKNOWN: d57c2000 <unknown>55 56mrrs x0, x1, TTBR1_EL257// CHECK-INST: mrrs x0, x1, TTBR1_EL258// CHECK-ENCODING: encoding: [0x20,0x20,0x7c,0xd5]59// CHECK-ERROR: error: instruction requires: d12860// CHECK-UNKNOWN: d57c2020 <unknown>61 62mrrs x0, x1, VTTBR_EL263// CHECK-INST: mrrs x0, x1, VTTBR_EL264// CHECK-ENCODING: encoding: [0x00,0x21,0x7c,0xd5]65// CHECK-ERROR: error: instruction requires: d12866// CHECK-UNKNOWN: d57c2100 <unknown>67 68mrrs x0, x1, VTTBR_EL269// CHECK-INST: mrrs x0, x1, VTTBR_EL270// CHECK-ENCODING: encoding: [0x00,0x21,0x7c,0xd5]71// CHECK-ERROR: error: instruction requires: d12872// CHECK-UNKNOWN: d57c2100 <unknown>73 74mrrs x2, x3, VTTBR_EL275// CHECK-INST: mrrs x2, x3, VTTBR_EL276// CHECK-ENCODING: encoding: [0x02,0x21,0x7c,0xd5]77// CHECK-ERROR: error: instruction requires: d12878// CHECK-UNKNOWN: d57c2102 <unknown>79 80mrrs x4, x5, VTTBR_EL281// CHECK-INST: mrrs x4, x5, VTTBR_EL282// CHECK-ENCODING: encoding: [0x04,0x21,0x7c,0xd5]83// CHECK-ERROR: error: instruction requires: d12884// CHECK-UNKNOWN: d57c2104 <unknown>85 86mrrs x6, x7, VTTBR_EL287// CHECK-INST: mrrs x6, x7, VTTBR_EL288// CHECK-ENCODING: encoding: [0x06,0x21,0x7c,0xd5]89// CHECK-ERROR: error: instruction requires: d12890// CHECK-UNKNOWN: d57c2106 <unknown>91 92mrrs x8, x9, VTTBR_EL293// CHECK-INST: mrrs x8, x9, VTTBR_EL294// CHECK-ENCODING: encoding: [0x08,0x21,0x7c,0xd5]95// CHECK-ERROR: error: instruction requires: d12896// CHECK-UNKNOWN: d57c2108 <unknown>97 98mrrs x10, x11, VTTBR_EL299// CHECK-INST: mrrs x10, x11, VTTBR_EL2100// CHECK-ENCODING: encoding: [0x0a,0x21,0x7c,0xd5]101// CHECK-ERROR: error: instruction requires: d128102// CHECK-UNKNOWN: d57c210a <unknown>103 104mrrs x12, x13, VTTBR_EL2105// CHECK-INST: mrrs x12, x13, VTTBR_EL2106// CHECK-ENCODING: encoding: [0x0c,0x21,0x7c,0xd5]107// CHECK-ERROR: error: instruction requires: d128108// CHECK-UNKNOWN: d57c210c <unknown>109 110mrrs x14, x15, VTTBR_EL2111// CHECK-INST: mrrs x14, x15, VTTBR_EL2112// CHECK-ENCODING: encoding: [0x0e,0x21,0x7c,0xd5]113// CHECK-ERROR: error: instruction requires: d128114// CHECK-UNKNOWN: d57c210e <unknown>115 116mrrs x16, x17, VTTBR_EL2117// CHECK-INST: mrrs x16, x17, VTTBR_EL2118// CHECK-ENCODING: encoding: [0x10,0x21,0x7c,0xd5]119// CHECK-ERROR: error: instruction requires: d128120// CHECK-UNKNOWN: d57c2110 <unknown>121 122mrrs x18, x19, VTTBR_EL2123// CHECK-INST: mrrs x18, x19, VTTBR_EL2124// CHECK-ENCODING: encoding: [0x12,0x21,0x7c,0xd5]125// CHECK-ERROR: error: instruction requires: d128126// CHECK-UNKNOWN: d57c2112 <unknown>127 128mrrs x20, x21, VTTBR_EL2129// CHECK-INST: mrrs x20, x21, VTTBR_EL2130// CHECK-ENCODING: encoding: [0x14,0x21,0x7c,0xd5]131// CHECK-ERROR: error: instruction requires: d128132// CHECK-UNKNOWN: d57c2114 <unknown>133 134mrrs x22, x23, VTTBR_EL2135// CHECK-INST: mrrs x22, x23, VTTBR_EL2136// CHECK-ENCODING: encoding: [0x16,0x21,0x7c,0xd5]137// CHECK-ERROR: error: instruction requires: d128138// CHECK-UNKNOWN: d57c2116 <unknown>139 140mrrs x24, x25, VTTBR_EL2141// CHECK-INST: mrrs x24, x25, VTTBR_EL2142// CHECK-ENCODING: encoding: [0x18,0x21,0x7c,0xd5]143// CHECK-ERROR: error: instruction requires: d128144// CHECK-UNKNOWN: d57c2118 <unknown>145 146mrrs x26, x27, VTTBR_EL2147// CHECK-INST: mrrs x26, x27, VTTBR_EL2148// CHECK-ENCODING: encoding: [0x1a,0x21,0x7c,0xd5]149// CHECK-ERROR: error: instruction requires: d128150// CHECK-UNKNOWN: d57c211a <unknown>151 152msrr TTBR0_EL1, x0, x1153// CHECK-INST: msrr TTBR0_EL1, x0, x1154// CHECK-ENCODING: encoding: [0x00,0x20,0x58,0xd5]155// CHECK-ERROR: :[[@LINE-3]]:1: error: instruction requires: d128156// CHECK-UNKNOWN: d5582000 <unknown>157 158msrr TTBR1_EL1, x0, x1159// CHECK-INST: msrr TTBR1_EL1, x0, x1160// CHECK-ENCODING: encoding: [0x20,0x20,0x58,0xd5]161// CHECK-ERROR: :[[@LINE-3]]:1: error: instruction requires: d128162// CHECK-UNKNOWN: d5582020 <unknown>163 164msrr PAR_EL1, x0, x1165// CHECK-INST: msrr PAR_EL1, x0, x1166// CHECK-ENCODING: encoding: [0x00,0x74,0x58,0xd5]167// CHECK-ERROR: :[[@LINE-3]]:1: error: instruction requires: d128168// CHECK-UNKNOWN: d5587400 <unknown>169 170msrr RCWSMASK_EL1, x0, x1171// CHECK-INST: msrr RCWSMASK_EL1, x0, x1172// CHECK-ENCODING: encoding: [0x60,0xd0,0x58,0xd5]173// CHECK-ERROR: :[[@LINE-3]]:1: error: instruction requires: d128174// CHECK-UNKNOWN: d558d060 <unknown>175 176msrr RCWMASK_EL1, x0, x1177// CHECK-INST: msrr RCWMASK_EL1, x0, x1178// CHECK-ENCODING: encoding: [0xc0,0xd0,0x58,0xd5]179// CHECK-ERROR: :[[@LINE-3]]:1: error: instruction requires: d128180// CHECK-UNKNOWN: d558d0c0 <unknown>181 182msrr TTBR0_EL2, x0, x1183// CHECK-INST: msrr TTBR0_EL2, x0, x1184// CHECK-ENCODING: encoding: [0x00,0x20,0x5c,0xd5]185// CHECK-ERROR: :[[@LINE-3]]:1: error: instruction requires: d128186// CHECK-UNKNOWN: d55c2000 <unknown>187 188msrr TTBR1_EL2, x0, x1189// CHECK-INST: msrr TTBR1_EL2, x0, x1190// CHECK-ENCODING: encoding: [0x20,0x20,0x5c,0xd5]191// CHECK-ERROR: :[[@LINE-3]]:1: error: instruction requires: d128192// CHECK-UNKNOWN: d55c2020 <unknown>193 194msrr VTTBR_EL2, x0, x1195// CHECK-INST: msrr VTTBR_EL2, x0, x1196// CHECK-ENCODING: encoding: [0x00,0x21,0x5c,0xd5]197// CHECK-ERROR: :[[@LINE-3]]:1: error: instruction requires: d128198// CHECK-UNKNOWN: d55c2100 <unknown>199 200msrr VTTBR_EL2, x0, x1201// CHECK-INST: msrr VTTBR_EL2, x0, x1202// CHECK-ENCODING: encoding: [0x00,0x21,0x5c,0xd5]203// CHECK-ERROR: :[[@LINE-3]]:1: error: instruction requires: d128204// CHECK-UNKNOWN: d55c2100 <unknown>205 206msrr VTTBR_EL2, x2, x3207// CHECK-INST: msrr VTTBR_EL2, x2, x3208// CHECK-ENCODING: encoding: [0x02,0x21,0x5c,0xd5]209// CHECK-ERROR: :[[@LINE-3]]:1: error: instruction requires: d128210// CHECK-UNKNOWN: d55c2102 <unknown>211 212msrr VTTBR_EL2, x4, x5213// CHECK-INST: msrr VTTBR_EL2, x4, x5214// CHECK-ENCODING: encoding: [0x04,0x21,0x5c,0xd5]215// CHECK-ERROR: :[[@LINE-3]]:1: error: instruction requires: d128216// CHECK-UNKNOWN: d55c2104 <unknown>217 218msrr VTTBR_EL2, x6, x7219// CHECK-INST: msrr VTTBR_EL2, x6, x7220// CHECK-ENCODING: encoding: [0x06,0x21,0x5c,0xd5]221// CHECK-ERROR: :[[@LINE-3]]:1: error: instruction requires: d128222// CHECK-UNKNOWN: d55c2106 <unknown>223 224msrr VTTBR_EL2, x8, x9225// CHECK-INST: msrr VTTBR_EL2, x8, x9226// CHECK-ENCODING: encoding: [0x08,0x21,0x5c,0xd5]227// CHECK-ERROR: :[[@LINE-3]]:1: error: instruction requires: d128228// CHECK-UNKNOWN: d55c2108 <unknown>229 230msrr VTTBR_EL2, x10, x11231// CHECK-INST: msrr VTTBR_EL2, x10, x11232// CHECK-ENCODING: encoding: [0x0a,0x21,0x5c,0xd5]233// CHECK-ERROR: :[[@LINE-3]]:1: error: instruction requires: d128234// CHECK-UNKNOWN: d55c210a <unknown>235 236msrr VTTBR_EL2, x12, x13237// CHECK-INST: msrr VTTBR_EL2, x12, x13238// CHECK-ENCODING: encoding: [0x0c,0x21,0x5c,0xd5]239// CHECK-ERROR: :[[@LINE-3]]:1: error: instruction requires: d128240// CHECK-UNKNOWN: d55c210c <unknown>241 242msrr VTTBR_EL2, x14, x15243// CHECK-INST: msrr VTTBR_EL2, x14, x15244// CHECK-ENCODING: encoding: [0x0e,0x21,0x5c,0xd5]245// CHECK-ERROR: :[[@LINE-3]]:1: error: instruction requires: d128246// CHECK-UNKNOWN: d55c210e <unknown>247 248msrr VTTBR_EL2, x16, x17249// CHECK-INST: msrr VTTBR_EL2, x16, x17250// CHECK-ENCODING: encoding: [0x10,0x21,0x5c,0xd5]251// CHECK-ERROR: :[[@LINE-3]]:1: error: instruction requires: d128252// CHECK-UNKNOWN: d55c2110 <unknown>253 254msrr VTTBR_EL2, x18, x19255// CHECK-INST: msrr VTTBR_EL2, x18, x19256// CHECK-ENCODING: encoding: [0x12,0x21,0x5c,0xd5]257// CHECK-ERROR: :[[@LINE-3]]:1: error: instruction requires: d128258// CHECK-UNKNOWN: d55c2112 <unknown>259 260msrr VTTBR_EL2, x20, x21261// CHECK-INST: msrr VTTBR_EL2, x20, x21262// CHECK-ENCODING: encoding: [0x14,0x21,0x5c,0xd5]263// CHECK-ERROR: :[[@LINE-3]]:1: error: instruction requires: d128264// CHECK-UNKNOWN: d55c2114 <unknown>265 266msrr VTTBR_EL2, x22, x23267// CHECK-INST: msrr VTTBR_EL2, x22, x23268// CHECK-ENCODING: encoding: [0x16,0x21,0x5c,0xd5]269// CHECK-ERROR: :[[@LINE-3]]:1: error: instruction requires: d128270// CHECK-UNKNOWN: d55c2116 <unknown>271 272msrr VTTBR_EL2, x24, x25273// CHECK-INST: msrr VTTBR_EL2, x24, x25274// CHECK-ENCODING: encoding: [0x18,0x21,0x5c,0xd5]275// CHECK-ERROR: :[[@LINE-3]]:1: error: instruction requires: d128276// CHECK-UNKNOWN: d55c2118 <unknown>277 278msrr VTTBR_EL2, x26, x27279// CHECK-INST: msrr VTTBR_EL2, x26, x27280// CHECK-ENCODING: encoding: [0x1a,0x21,0x5c,0xd5]281// CHECK-ERROR: :[[@LINE-3]]:1: error: instruction requires: d128282// CHECK-UNKNOWN: d55c211a <unknown>283