25 lines · plain
1; RUN: llc -o - %s -mtriple=arm64-apple-ios -O2 | FileCheck %s2; RUN: llc -o - %s -mtriple=arm64_32-apple-ios -O2 | FileCheck %s3; Test case for <rdar://problem/15942912>.4; AdrpAddStr cannot be used when the store uses same5; register as address and value. Indeed, the related6; if applied, may completely remove the definition or7; at least provide a wrong one (with the offset folded8; into the definition).9 10%struct.anon = type { ptr, ptr }11 12@pptp_wan_head = internal global %struct.anon zeroinitializer, align 813 14; CHECK-LABEL: _pptp_wan_init15; CHECK: ret16; CHECK-NOT: AdrpAddStr17define i32 @pptp_wan_init() {18entry:19 store ptr null, ptr @pptp_wan_head, align 820 store ptr @pptp_wan_head, ptr getelementptr inbounds (%struct.anon, ptr @pptp_wan_head, i64 0, i32 1), align 821 ret i32 022}23 24 25