1 ; RUN: llc < %s -mtriple=arm64-apple-ios | FileCheck %s --check-prefix=CHECK-IOS
2 ; RUN: llc < %s -mtriple=arm64-apple-ios -global-isel | FileCheck %s --check-prefix=CHECK-IOS
3 ; RUN: llc < %s -mtriple=arm64-linux-gnu | FileCheck %s --check-prefix=CHECK-LINUX
4 ; RUN: llc < %s -mtriple=arm64-linux-gnu -code-model=large| FileCheck %s --check-prefix=CHECK-LARGE
8 define i64 @t() nounwind ssp {
11 ; CHECK-IOS: .quad Ltmp0
12 ; CHECK-IOS-LABEL: _t:
13 ; CHECK-IOS: adrp x[[TMP:[0-9]+]], lCPI0_0@PAGE
14 ; CHECK-IOS: ldr {{x[0-9]+}}, [x[[TMP]], lCPI0_0@PAGEOFF]
16 ; CHECK-LINUX-LABEL: t:
17 ; CHECK-LINUX: adrp [[REG:x[0-9]+]], .Ltmp0
18 ; CHECK-LINUX: add {{x[0-9]+}}, [[REG]], :lo12:.Ltmp0
20 ; CHECK-LARGE-LABEL: t:
21 ; CHECK-LARGE: movz [[ADDR_REG:x[0-9]+]], #:abs_g0_nc:[[DEST_LBL:.Ltmp[0-9]+]]
22 ; CHECK-LARGE: movk [[ADDR_REG]], #:abs_g1_nc:[[DEST_LBL]]
23 ; CHECK-LARGE: movk [[ADDR_REG]], #:abs_g2_nc:[[DEST_LBL]]
24 ; CHECK-LARGE: movk [[ADDR_REG]], #:abs_g3:[[DEST_LBL]]
26 %recover = alloca i64, align 8
27 store volatile i64 ptrtoint (ptr blockaddress(@t, %mylabel) to i64), ptr %recover, align 8
31 %tmp = load volatile i64, ptr %recover, align 8