• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1// RUN: llvm-mc -triple aarch64-none-linux-gnu -show-encoding -mattr=+v8.5a < %s | FileCheck %s
2// RUN: llvm-mc -triple aarch64-none-linux-gnu -show-encoding -mattr=+v8.4a,+fptoint < %s | FileCheck %s
3// RUN: not llvm-mc -triple aarch64-none-linux-gnu -show-encoding -mattr=+v8.4a,-v8.5a < %s 2>&1 | FileCheck %s --check-prefix=NOFRINT
4// RUN: not llvm-mc -triple aarch64-none-linux-gnu -show-encoding -mattr=-v8.5a < %s 2>&1 | FileCheck %s --check-prefix=NOFRINT
5
6// FP-to-int rounding, scalar
7frint32z s0, s1
8frint32z d0, d1
9frint64z s2, s3
10frint64z d2, d3
11frint32x s4, s5
12frint32x d4, d5
13frint64x s6, s7
14frint64x d6, d7
15
16// CHECK: frint32z s0, s1                 // encoding: [0x20,0x40,0x28,0x1e]
17// CHECK: frint32z d0, d1                 // encoding: [0x20,0x40,0x68,0x1e]
18// CHECK: frint64z s2, s3                 // encoding: [0x62,0x40,0x29,0x1e]
19// CHECK: frint64z d2, d3                 // encoding: [0x62,0x40,0x69,0x1e]
20// CHECK: frint32x s4, s5                 // encoding: [0xa4,0xc0,0x28,0x1e]
21// CHECK: frint32x d4, d5                 // encoding: [0xa4,0xc0,0x68,0x1e]
22// CHECK: frint64x s6, s7                 // encoding: [0xe6,0xc0,0x29,0x1e]
23// CHECK: frint64x d6, d7                 // encoding: [0xe6,0xc0,0x69,0x1e]
24
25// NOFRINT: instruction requires: frint3264
26// NOFRINT-NEXT: frint32z s0, s1
27// NOFRINT: instruction requires: frint3264
28// NOFRINT-NEXT: frint32z d0, d1
29// NOFRINT: instruction requires: frint3264
30// NOFRINT-NEXT: frint64z s2, s3
31// NOFRINT: instruction requires: frint3264
32// NOFRINT-NEXT: frint64z d2, d3
33// NOFRINT: instruction requires: frint3264
34// NOFRINT-NEXT: frint32x s4, s5
35// NOFRINT: instruction requires: frint3264
36// NOFRINT-NEXT: frint32x d4, d5
37// NOFRINT: instruction requires: frint3264
38// NOFRINT-NEXT: frint64x s6, s7
39// NOFRINT: instruction requires: frint3264
40// NOFRINT-NEXT: frint64x d6, d7
41
42// FP-to-int rounding, vector
43frint32z v0.2s, v1.2s
44frint32z v0.2d, v1.2d
45frint32z v0.4s, v1.4s
46frint64z v2.2s, v3.2s
47frint64z v2.2d, v3.2d
48frint64z v2.4s, v3.4s
49frint32x v4.2s, v5.2s
50frint32x v4.2d, v5.2d
51frint32x v4.4s, v5.4s
52frint64x v6.2s, v7.2s
53frint64x v6.2d, v7.2d
54frint64x v6.4s, v7.4s
55
56// CHECK: frint32z v0.2s, v1.2s           // encoding: [0x20,0xe8,0x21,0x0e]
57// CHECK: frint32z v0.2d, v1.2d           // encoding: [0x20,0xe8,0x61,0x4e]
58// CHECK: frint32z v0.4s, v1.4s           // encoding: [0x20,0xe8,0x21,0x4e]
59// CHECK: frint64z v2.2s, v3.2s           // encoding: [0x62,0xf8,0x21,0x0e]
60// CHECK: frint64z v2.2d, v3.2d           // encoding: [0x62,0xf8,0x61,0x4e]
61// CHECK: frint64z v2.4s, v3.4s           // encoding: [0x62,0xf8,0x21,0x4e]
62// CHECK: frint32x v4.2s, v5.2s           // encoding: [0xa4,0xe8,0x21,0x2e]
63// CHECK: frint32x v4.2d, v5.2d           // encoding: [0xa4,0xe8,0x61,0x6e]
64// CHECK: frint32x v4.4s, v5.4s           // encoding: [0xa4,0xe8,0x21,0x6e]
65// CHECK: frint64x v6.2s, v7.2s           // encoding: [0xe6,0xf8,0x21,0x2e]
66// CHECK: frint64x v6.2d, v7.2d           // encoding: [0xe6,0xf8,0x61,0x6e]
67// CHECK: frint64x v6.4s, v7.4s           // encoding: [0xe6,0xf8,0x21,0x6e]
68
69// NOFRINT: instruction requires: frint3264
70// NOFRINT-NEXT: frint32z v0.2s, v1.2s
71// NOFRINT: instruction requires: frint3264
72// NOFRINT-NEXT: frint32z v0.2d, v1.2d
73// NOFRINT: instruction requires: frint3264
74// NOFRINT-NEXT: frint32z v0.4s, v1.4s
75// NOFRINT: instruction requires: frint3264
76// NOFRINT-NEXT: frint64z v2.2s, v3.2s
77// NOFRINT: instruction requires: frint3264
78// NOFRINT-NEXT: frint64z v2.2d, v3.2d
79// NOFRINT: instruction requires: frint3264
80// NOFRINT-NEXT: frint64z v2.4s, v3.4s
81// NOFRINT: instruction requires: frint3264
82// NOFRINT-NEXT: frint32x v4.2s, v5.2s
83// NOFRINT: instruction requires: frint3264
84// NOFRINT-NEXT: frint32x v4.2d, v5.2d
85// NOFRINT: instruction requires: frint3264
86// NOFRINT-NEXT: frint32x v4.4s, v5.4s
87// NOFRINT: instruction requires: frint3264
88// NOFRINT-NEXT: frint64x v6.2s, v7.2s
89// NOFRINT: instruction requires: frint3264
90// NOFRINT-NEXT: frint64x v6.2d, v7.2d
91// NOFRINT: instruction requires: frint3264
92// NOFRINT-NEXT: frint64x v6.4s, v7.4s
93