xref: /aosp_15_r20/external/llvm/test/CodeGen/ARM/hints.ll (revision 9880d6810fe72a1726cb53787c6711e909410d58)
1*9880d681SAndroid Build Coastguard Worker; RUN: llc -mtriple armv7-eabi -o - %s | FileCheck %s
2*9880d681SAndroid Build Coastguard Worker; RUN: llc -mtriple thumbv6m-eabi -o - %s | FileCheck %s
3*9880d681SAndroid Build Coastguard Worker; RUN: llc -mtriple thumbv7-eabi -o - %s | FileCheck %s
4*9880d681SAndroid Build Coastguard Worker
5*9880d681SAndroid Build Coastguard Workerdeclare void @llvm.arm.hint(i32) nounwind
6*9880d681SAndroid Build Coastguard Worker
7*9880d681SAndroid Build Coastguard Workerdefine void @hint_nop() {
8*9880d681SAndroid Build Coastguard Workerentry:
9*9880d681SAndroid Build Coastguard Worker  tail call void @llvm.arm.hint(i32 0) nounwind
10*9880d681SAndroid Build Coastguard Worker  ret void
11*9880d681SAndroid Build Coastguard Worker}
12*9880d681SAndroid Build Coastguard Worker
13*9880d681SAndroid Build Coastguard Worker; CHECK-LABEL: hint_nop
14*9880d681SAndroid Build Coastguard Worker; CHECK: nop
15*9880d681SAndroid Build Coastguard Worker
16*9880d681SAndroid Build Coastguard Workerdefine void @hint_yield() {
17*9880d681SAndroid Build Coastguard Workerentry:
18*9880d681SAndroid Build Coastguard Worker  tail call void @llvm.arm.hint(i32 1) nounwind
19*9880d681SAndroid Build Coastguard Worker  ret void
20*9880d681SAndroid Build Coastguard Worker}
21*9880d681SAndroid Build Coastguard Worker
22*9880d681SAndroid Build Coastguard Worker; CHECK-LABEL: hint_yield
23*9880d681SAndroid Build Coastguard Worker; CHECK: yield
24*9880d681SAndroid Build Coastguard Worker
25*9880d681SAndroid Build Coastguard Workerdefine void @hint_wfe() {
26*9880d681SAndroid Build Coastguard Workerentry:
27*9880d681SAndroid Build Coastguard Worker  tail call void @llvm.arm.hint(i32 2) nounwind
28*9880d681SAndroid Build Coastguard Worker  ret void
29*9880d681SAndroid Build Coastguard Worker}
30*9880d681SAndroid Build Coastguard Worker
31*9880d681SAndroid Build Coastguard Worker; CHECK-LABEL: hint_wfe
32*9880d681SAndroid Build Coastguard Worker; CHECK: wfe
33*9880d681SAndroid Build Coastguard Worker
34*9880d681SAndroid Build Coastguard Workerdefine void @hint_wfi() {
35*9880d681SAndroid Build Coastguard Workerentry:
36*9880d681SAndroid Build Coastguard Worker  tail call void @llvm.arm.hint(i32 3) nounwind
37*9880d681SAndroid Build Coastguard Worker  ret void
38*9880d681SAndroid Build Coastguard Worker}
39*9880d681SAndroid Build Coastguard Worker
40*9880d681SAndroid Build Coastguard Worker; CHECK-LABEL: hint_wfi
41*9880d681SAndroid Build Coastguard Worker; CHECK: wfi
42*9880d681SAndroid Build Coastguard Worker
43*9880d681SAndroid Build Coastguard Workerdefine void @hint_sev() {
44*9880d681SAndroid Build Coastguard Workerentry:
45*9880d681SAndroid Build Coastguard Worker  tail call void @llvm.arm.hint(i32 4) nounwind
46*9880d681SAndroid Build Coastguard Worker  ret void
47*9880d681SAndroid Build Coastguard Worker}
48*9880d681SAndroid Build Coastguard Worker
49*9880d681SAndroid Build Coastguard Worker; CHECK-LABEL: hint_sev
50*9880d681SAndroid Build Coastguard Worker; CHECK: sev
51*9880d681SAndroid Build Coastguard Worker
52*9880d681SAndroid Build Coastguard Workerdefine void @hint_sevl() {
53*9880d681SAndroid Build Coastguard Workerentry:
54*9880d681SAndroid Build Coastguard Worker  tail call void @llvm.arm.hint(i32 5) nounwind
55*9880d681SAndroid Build Coastguard Worker  ret void
56*9880d681SAndroid Build Coastguard Worker}
57*9880d681SAndroid Build Coastguard Worker
58*9880d681SAndroid Build Coastguard Worker; CHECK-LABEL: hint_sevl
59*9880d681SAndroid Build Coastguard Worker; CHECK: hint #5
60*9880d681SAndroid Build Coastguard Worker
61*9880d681SAndroid Build Coastguard Workerdefine void @hint_undefined() {
62*9880d681SAndroid Build Coastguard Workerentry:
63*9880d681SAndroid Build Coastguard Worker  tail call void @llvm.arm.hint(i32 8) nounwind
64*9880d681SAndroid Build Coastguard Worker  ret void
65*9880d681SAndroid Build Coastguard Worker}
66*9880d681SAndroid Build Coastguard Worker
67*9880d681SAndroid Build Coastguard Worker; CHECK-LABEL: hint_undefined
68*9880d681SAndroid Build Coastguard Worker; CHECK: hint #8
69*9880d681SAndroid Build Coastguard Worker
70