File: armv8.4a-dit.s

package info (click to toggle)
llvm-toolchain-9 1%3A9.0.1-16.1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 882,388 kB
  • sloc: cpp: 4,167,636; ansic: 714,256; asm: 457,610; python: 155,927; objc: 65,094; sh: 42,856; lisp: 26,908; perl: 7,786; pascal: 7,722; makefile: 6,881; ml: 5,581; awk: 3,648; cs: 2,027; xml: 888; javascript: 381; ruby: 156
file content (42 lines) | stat: -rw-r--r-- 1,769 bytes parent folder | download | duplicates (13)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
// RUN: not llvm-mc -triple aarch64-none-linux-gnu -show-encoding -mattr=+v8.4a < %s 2> %t  | FileCheck %s --check-prefix=CHECK
// RUN: FileCheck --check-prefix=CHECK-ERROR < %t %s
// RUN: not llvm-mc -triple aarch64-none-linux-gnu -show-encoding -mattr=-v8.4a < %s 2>&1 | FileCheck %s --check-prefix=CHECK-NO-V84

//------------------------------------------------------------------------------
// ARMV8.4-A Timing insensitivity of data processing instructions
//------------------------------------------------------------------------------

msr DIT, #1
msr DIT, x0
mrs x0, DIT

//CHECK:      msr DIT, #1                 // encoding: [0x5f,0x41,0x03,0xd5]
//CHECK-NEXT: msr DIT, x0                 // encoding: [0xa0,0x42,0x1b,0xd5]
//CHECK-NEXT: mrs x0, DIT                 // encoding: [0xa0,0x42,0x3b,0xd5]

msr DIT, #2
msr DIT, #-1

//CHECK-ERROR:      error: immediate must be an integer in range [0, 1].
//CHECK-ERROR-NEXT: msr DIT, #2
//CHECK-ERROR-NEXT:          ^
//CHECK-ERROR-NEXT: error: immediate must be an integer in range [0, 1].
//CHECK-ERROR-NEXT: msr DIT, #-1
//CHECK-ERROR-NEXT:          ^

//CHECK-NO-V84:      error: expected writable system register or pstate
//CHECK-NO-V84-NEXT: msr DIT, #1
//CHECK-NO-V84-NEXT:     ^
//CHECK-NO-V84-NEXT: error: expected writable system register or pstate
//CHECK-NO-V84-NEXT: msr DIT, x0
//CHECK-NO-V84-NEXT:     ^
//CHECK-NO-V84-NEXT: error: expected readable system register
//CHECK-NO-V84-NEXT: mrs x0, DIT
//CHECK-NO-V84-NEXT:         ^
//CHECK-NO-V84-NEXT: error: expected writable system register or pstate
//CHECK-NO-V84-NEXT: msr DIT, #2
//CHECK-NO-V84-NEXT:     ^
//CHECK-NO-V84-NEXT: error: expected writable system register or pstate
//CHECK-NO-V84-NEXT: msr DIT, #-1
//CHECK-NO-V84-NEXT:     ^