1 ; RUN: llc < %s -mtriple=arm64-eabi | FileCheck %s
3 define i8* @rt0(i32 %x) nounwind readnone {
8 %0 = tail call i8* @llvm.returnaddress(i32 0)
12 define i8* @rt2() nounwind readnone {
15 ; CHECK: stp x29, x30, [sp, #-16]!
17 ; CHECK: ldr x[[REG:[0-9]+]], [x29]
18 ; CHECK: ldr x[[REG2:[0-9]+]], [x[[REG]]]
19 ; CHECK: ldr x0, [x[[REG2]], #8]
20 ; CHECK: ldp x29, x30, [sp], #16
22 %0 = tail call i8* @llvm.returnaddress(i32 2)
26 declare i8* @llvm.returnaddress(i32) nounwind readnone