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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
|
// RUN: %clang_cc1 -O2 -emit-llvm %s -o - -triple aarch64 | FileCheck %s
int test_cceq(int a, int* b) {
// CHECK-LABEL: @test_cceq
// CHECK: = tail call { i32, i32 } asm "ands ${0:w}, ${0:w}, #3", "=r,={@cceq},0"(i32 %a)
asm("ands %w[a], %w[a], #3"
: [a] "+r"(a), "=@cceq"(*b));
return a;
}
int test_ccne(int a, int* b) {
// CHECK-LABEL: @test_ccne
// CHECK: = tail call { i32, i32 } asm "ands ${0:w}, ${0:w}, #3", "=r,={@ccne},0"(i32 %a)
asm("ands %w[a], %w[a], #3"
: [a] "+r"(a), "=@ccne"(*b));
return a;
}
int test_cccs(int a, int* b) {
// CHECK-LABEL: @test_cccs
// CHECK: = tail call { i32, i32 } asm "ands ${0:w}, ${0:w}, #3", "=r,={@cccs},0"(i32 %a)
asm("ands %w[a], %w[a], #3"
: [a] "+r"(a), "=@cccs"(*b));
return a;
}
int test_cchs(int a, int* b) {
// CHECK-LABEL: @test_cchs
// CHECK: = tail call { i32, i32 } asm "ands ${0:w}, ${0:w}, #3", "=r,={@cchs},0"(i32 %a)
asm("ands %w[a], %w[a], #3"
: [a] "+r"(a), "=@cchs"(*b));
return a;
}
int test_cccc(int a, int* b) {
// CHECK-LABEL: @test_cccc
// CHECK: = tail call { i32, i32 } asm "ands ${0:w}, ${0:w}, #3", "=r,={@cccc},0"(i32 %a)
asm("ands %w[a], %w[a], #3"
: [a] "+r"(a), "=@cccc"(*b));
return a;
}
int test_cclo(int a, int* b) {
// CHECK-LABEL: @test_cclo
// CHECK: = tail call { i32, i32 } asm "ands ${0:w}, ${0:w}, #3", "=r,={@cclo},0"(i32 %a)
asm("ands %w[a], %w[a], #3"
: [a] "+r"(a), "=@cclo"(*b));
return a;
}
int test_ccmi(int a, int* b) {
// CHECK-LABEL: @test_ccmi
// CHECK: = tail call { i32, i32 } asm "ands ${0:w}, ${0:w}, #3", "=r,={@ccmi},0"(i32 %a)
asm("ands %w[a], %w[a], #3"
: [a] "+r"(a), "=@ccmi"(*b));
return a;
}
int test_ccpl(int a, int* b) {
// CHECK-LABEL: @test_ccpl
// CHECK: = tail call { i32, i32 } asm "ands ${0:w}, ${0:w}, #3", "=r,={@ccpl},0"(i32 %a)
asm("ands %w[a], %w[a], #3"
: [a] "+r"(a), "=@ccpl"(*b));
return a;
}
int test_ccvs(int a, int* b) {
// CHECK-LABEL: @test_ccvs
// CHECK: = tail call { i32, i32 } asm "ands ${0:w}, ${0:w}, #3", "=r,={@ccvs},0"(i32 %a)
asm("ands %w[a], %w[a], #3"
: [a] "+r"(a), "=@ccvs"(*b));
return a;
}
int test_ccvc(int a, int* b) {
// CHECK-LABEL: @test_ccvc
// CHECK: = tail call { i32, i32 } asm "ands ${0:w}, ${0:w}, #3", "=r,={@ccvc},0"(i32 %a)
asm("ands %w[a], %w[a], #3"
: [a] "+r"(a), "=@ccvc"(*b));
return a;
}
int test_cchi(int a, int* b) {
// CHECK-LABEL: @test_cchi
// CHECK: = tail call { i32, i32 } asm "ands ${0:w}, ${0:w}, #3", "=r,={@cchi},0"(i32 %a)
asm("ands %w[a], %w[a], #3"
: [a] "+r"(a), "=@cchi"(*b));
return a;
}
int test_ccls(int a, int* b) {
// CHECK-LABEL: @test_ccls
// CHECK: = tail call { i32, i32 } asm "ands ${0:w}, ${0:w}, #3", "=r,={@ccls},0"(i32 %a)
asm("ands %w[a], %w[a], #3"
: [a] "+r"(a), "=@ccls"(*b));
return a;
}
int test_ccge(int a, int* b) {
// CHECK-LABEL: @test_ccge
// CHECK: = tail call { i32, i32 } asm "ands ${0:w}, ${0:w}, #3", "=r,={@ccge},0"(i32 %a)
asm("ands %w[a], %w[a], #3"
: [a] "+r"(a), "=@ccge"(*b));
return a;
}
int test_cclt(int a, int* b) {
// CHECK-LABEL: @test_cclt
// CHECK: = tail call { i32, i32 } asm "ands ${0:w}, ${0:w}, #3", "=r,={@cclt},0"(i32 %a)
asm("ands %w[a], %w[a], #3"
: [a] "+r"(a), "=@cclt"(*b));
return a;
}
int test_ccgt(int a, int* b) {
// CHECK-LABEL: @test_ccgt
// CHECK: = tail call { i32, i32 } asm "ands ${0:w}, ${0:w}, #3", "=r,={@ccgt},0"(i32 %a)
asm("ands %w[a], %w[a], #3"
: [a] "+r"(a), "=@ccgt"(*b));
return a;
}
int test_ccle(int a, int* b) {
// CHECK-LABEL: @test_ccle
// CHECK: = tail call { i32, i32 } asm "ands ${0:w}, ${0:w}, #3", "=r,={@ccle},0"(i32 %a)
asm("ands %w[a], %w[a], #3"
: [a] "+r"(a), "=@ccle"(*b));
return a;
}
|