58 lines · plain
1// CLRBHB is optional for all v8a/v9a, mandatory for 8.9a/9.4a.2// Assembly is always permitted for instructions in the hint space.3 4// Optional, off by default5// RUN: llvm-mc -show-encoding -triple aarch64 < %s | FileCheck %s --check-prefix=HINT_226// RUN: llvm-mc -show-encoding -triple aarch64 -mattr=+v8a < %s | FileCheck %s --check-prefix=HINT_227// RUN: llvm-mc -show-encoding -triple aarch64 -mattr=+v8.8a < %s | FileCheck %s --check-prefix=HINT_228// RUN: llvm-mc -show-encoding -triple aarch64 -mattr=+v9a < %s | FileCheck %s --check-prefix=HINT_229// RUN: llvm-mc -show-encoding -triple aarch64 -mattr=+v9.3a < %s | FileCheck %s --check-prefix=HINT_2210 11// Optional, off by default, doubly disabled12// RUN: llvm-mc -show-encoding -triple aarch64 -mattr=-clrbhb < %s | FileCheck %s --check-prefix=HINT_2213// RUN: llvm-mc -show-encoding -triple aarch64 -mattr=+v8a,-clrbhb < %s | FileCheck %s --check-prefix=HINT_2214// RUN: llvm-mc -show-encoding -triple aarch64 -mattr=+v8.8a,-clrbhb < %s | FileCheck %s --check-prefix=HINT_2215// RUN: llvm-mc -show-encoding -triple aarch64 -mattr=+v9a,-clrbhb < %s | FileCheck %s --check-prefix=HINT_2216// RUN: llvm-mc -show-encoding -triple aarch64 -mattr=+v9.3a,-clrbhb < %s | FileCheck %s --check-prefix=HINT_2217 18// Optional, off by default, manually enabled19// RUN: llvm-mc -show-encoding -triple aarch64 -mattr=+clrbhb < %s | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST20// RUN: llvm-mc -show-encoding -triple aarch64 -mattr=+v8a,+clrbhb < %s | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST21// RUN: llvm-mc -show-encoding -triple aarch64 -mattr=+v8.8a,+clrbhb < %s | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST22// RUN: llvm-mc -show-encoding -triple aarch64 -mattr=+v9a,+clrbhb < %s | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST23// RUN: llvm-mc -show-encoding -triple aarch64 -mattr=+v9.3a,+clrbhb < %s | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST24 25// Mandatory, enabled by default26// RUN: llvm-mc -show-encoding -triple aarch64 -mattr=+v8.9a < %s | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST27// RUN: llvm-mc -show-encoding -triple aarch64 -mattr=+v9.4a < %s | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST28 29// Mandatory, on by default, doubly enabled30// RUN: llvm-mc -show-encoding -triple aarch64 -mattr=+v8.9a,+clrbhb < %s | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST31// RUN: llvm-mc -show-encoding -triple aarch64 -mattr=+v9.4a,+clrbhb < %s | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST32 33// Mandatory, can't prevent disabling in LLVM34// RUN: llvm-mc -show-encoding -triple aarch64 -mattr=+v8.9a,-clrbhb < %s | FileCheck %s --check-prefix=HINT_2235// RUN: llvm-mc -show-encoding -triple aarch64 -mattr=+v9.4a,-clrbhb < %s | FileCheck %s --check-prefix=HINT_2236 37// Check Unknown38// RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+clrbhb < %s \39// RUN: | llvm-objdump -d --mattr=-clrbhb --no-print-imm-hex - | FileCheck %s --check-prefix=CHECK-UNKNOWN40 41// Disassemble encoding and check the re-encoding (-show-encoding) matches.42// RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+clrbhb < %s \43// RUN: | sed '/.text/d' | sed 's/.*encoding: //g' \44// RUN: | llvm-mc -triple=aarch64 -mattr=+clrbhb -disassemble -show-encoding \45// RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST46 47clrbhb48// HINT_22: hint #22 // encoding: [0xdf,0x22,0x03,0xd5]49// CHECK-INST: clrbhb50// CHECK-ENCODING: encoding: [0xdf,0x22,0x03,0xd5]51// CHECK-UNKNOWN: d50322df hint #2252 53hint #2254// HINT_22: hint #22 // encoding: [0xdf,0x22,0x03,0xd5]55// CHECK-INST: clrbhb56// CHECK-ENCODING: encoding: [0xdf,0x22,0x03,0xd5]57// CHECK-UNKNOWN: d50322df hint #2258