1 ; RUN: llc -mtriple aarch64-arm-linux-gnu --enable-machine-outliner \
2 ; RUN: -verify-machineinstrs %s -o - | FileCheck --check-prefixes CHECK,V8A %s
3 ; RUN-V83A: llc -mtriple aarch64 -enable-machine-outliner \
4 ; RUN-V83A: -verify-machineinstrs -mattr=+v8.3a %s -o - > %t
5 ; RUN-V83A: FileCheck --check-prefixes CHECK,V83A < %t %s
7 declare i32 @thunk_called_fn(i32, i32, i32, i32)
10 ; CHECK-LABEL: a: // @a
11 ; CHECK: // %bb.0: // %entry
14 ; CHECK-NEXT: .cfi_negate_ra_state
19 %call = tail call i32 @thunk_called_fn(i32 1, i32 2, i32 3, i32 4)
20 %cx = add i32 %call, 8
25 ; CHECK-LABEL: b: // @b
26 ; CHECK: // %bb.0: // %entry
29 ; CHECK-NEXT: .cfi_negate_ra_state
34 %call = tail call i32 @thunk_called_fn(i32 1, i32 2, i32 3, i32 4)
35 %cx = add i32 %call, 88
39 define hidden i32 @c(ptr %fptr) #0 {
40 ; CHECK-LABEL: c: // @c
41 ; CHECK: // %bb.0: // %entry
44 ; CHECK-NEXT: .cfi_negate_ra_state
49 %call = tail call i32 %fptr(i32 1, i32 2, i32 3, i32 4)
50 %add = add nsw i32 %call, 8
54 define hidden i32 @d(ptr %fptr) #0 {
55 ; CHECK-LABEL: d: // @d
56 ; CHECK: // %bb.0: // %entry
59 ; CHECK-NEXT: .cfi_negate_ra_state
64 %call = tail call i32 %fptr(i32 1, i32 2, i32 3, i32 4)
65 %add = add nsw i32 %call, 88
69 attributes #0 = { "sign-return-address"="non-leaf" minsize }
71 ; CHECK-NOT: OUTLINED_FUNCTION_{{.*}}
72 ; CHECK-NOT: .cfi_b_key_frame
73 ; CHECK-NOT: paci{{[a,b]}}sp
74 ; CHECK-NOT: hint #2{{[5,7]}}
75 ; CHECK-NOT: .cfi_negate_ra_state
76 ; CHECK-NOT: auti{{[a,b]}}sp
77 ; CHECK-NOT: hint #{{[29,31]}}