1 ; RUN: opt -safe-stack -S -mtriple=arm-linux-android < %s -o - | FileCheck %s 2 3 4 define void @foo() nounwind uwtable safestack { 5 entry: 6 ; CHECK: %[[SPA:.*]] = call i8** @__safestack_pointer_address() 7 ; CHECK: %[[USP:.*]] = load i8*, i8** %[[SPA]] 8 ; CHECK: %[[USST:.*]] = getelementptr i8, i8* %[[USP]], i32 -16 9 ; CHECK: store i8* %[[USST]], i8** %[[SPA]] 10 11 %a = alloca i8, align 8 12 call void @Capture(i8* %a) 13 14 ; CHECK: store i8* %[[USP]], i8** %[[SPA]] 15 ret void 16 } 17 18 declare void @Capture(i8*) 19