Skip to content

Commit d9cfb82

Browse files
committed
[AArch64] Add test for #70207 (NFC)
1 parent 2005f48 commit d9cfb82

File tree

1 file changed

+33
-0
lines changed

1 file changed

+33
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py UTC_ARGS: --version 3
2+
; RUN: llc -mtriple=aarch64-unknown-linux-gnu -global-isel < %s | FileCheck %s
3+
4+
declare void @func(i64, i64, i64, i64, i64, i128, i128)
5+
6+
; FIXME: This is a miscompile.
7+
; Make sure the check for whether a tail call is allowed does not affect the
8+
; calling convention if it fails.
9+
; The first i128 argument should be passed in registers, not on the stack.
10+
define void @pr70207(i128 %arg1, i128 %arg2) nounwind {
11+
; CHECK-LABEL: pr70207:
12+
; CHECK: // %bb.0:
13+
; CHECK-NEXT: sub sp, sp, #64
14+
; CHECK-NEXT: mov x6, x0
15+
; CHECK-NEXT: mov x8, x1
16+
; CHECK-NEXT: mov x9, x2
17+
; CHECK-NEXT: mov x10, x3
18+
; CHECK-NEXT: mov x0, xzr
19+
; CHECK-NEXT: mov x1, xzr
20+
; CHECK-NEXT: mov x2, xzr
21+
; CHECK-NEXT: mov x3, xzr
22+
; CHECK-NEXT: mov x4, xzr
23+
; CHECK-NEXT: str x30, [sp, #48] // 8-byte Folded Spill
24+
; CHECK-NEXT: str x8, [sp]
25+
; CHECK-NEXT: str x9, [sp, #16]
26+
; CHECK-NEXT: str x10, [sp, #32]
27+
; CHECK-NEXT: bl func
28+
; CHECK-NEXT: ldr x30, [sp, #48] // 8-byte Folded Reload
29+
; CHECK-NEXT: add sp, sp, #64
30+
; CHECK-NEXT: ret
31+
tail call void @func(i64 0, i64 0, i64 0, i64 0, i64 0, i128 %arg1, i128 %arg2)
32+
ret void
33+
}

0 commit comments

Comments
 (0)