brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.9 KiB · 0ee075c Raw
45 lines · plain
1; RUN: llc < %s -mtriple=thumbv7-apple-ios -relocation-model=pic -no-integrated-as | FileCheck %s -check-prefix=PIC2; RUN: llc < %s -mtriple=thumbv7-apple-ios -relocation-model=static -no-integrated-as | FileCheck %s -check-prefix=STATIC3; RUN: llc < %s -mtriple=thumbv7-apple-ios -relocation-model=dynamic-no-pic -no-integrated-as | FileCheck %s  -check-prefix=DYNAMIC-NO-PIC4 5;PIC:   foo26;PIC:   movw  [[R0:r[0-9]+]], :lower16:(L___stack_chk_guard$non_lazy_ptr-([[LABEL0:LPC[0-9_]+]]+4))7;PIC:   movt  [[R0]], :upper16:(L___stack_chk_guard$non_lazy_ptr-([[LABEL0]]+4))8;PIC: [[LABEL0]]:9;PIC:   add [[R0]], pc10;PIC:   ldr [[R1:r[0-9]+]], [[[R0]]]11;PIC:   ldr {{r[0-9]+}}, [[[R1]]]12 13;STATIC:   foo214;STATIC:   movw  [[R0:r[0-9]+]], :lower16:___stack_chk_guard15;STATIC:   movt  [[R0]], :upper16:___stack_chk_guard16;STATIC:   ldr {{r[0-9]+}}, [[[R0]]]17 18;DYNAMIC-NO-PIC:   foo219;DYNAMIC-NO-PIC:   movw  [[R0:r[0-9]+]], :lower16:L___stack_chk_guard$non_lazy_ptr20;DYNAMIC-NO-PIC:   movt  [[R0]], :upper16:L___stack_chk_guard$non_lazy_ptr21;DYNAMIC-NO-PIC:   ldr {{r[0-9]+}}, [[[R0]]]22 23; Function Attrs: nounwind ssp24define i32 @test_stack_guard_remat() #0 {25  %a1 = alloca [256 x i32], align 426  call void @llvm.lifetime.start.p0(i64 1024, ptr %a1)27  call void @foo3(ptr %a1) #328  call void asm sideeffect "foo2", "~{r0},~{r1},~{r2},~{r3},~{r4},~{r5},~{r6},~{r7},~{r8},~{r9},~{r10},~{r11},~{r12},~{sp},~{lr}"()29  call void @llvm.lifetime.end.p0(i64 1024, ptr %a1)30  ret i32 031}32 33; Function Attrs: nounwind34declare void @llvm.lifetime.start.p0(i64, ptr nocapture)35 36declare void @foo3(ptr)37 38; Function Attrs: nounwind39declare void @llvm.lifetime.end.p0(i64, ptr nocapture)40 41attributes #0 = { nounwind ssp "less-precise-fpmad"="false" "frame-pointer"="all" "no-infs-fp-math"="false" "no-nans-fp-math"="false" "stack-protector-buffer-size"="8" "use-soft-float"="false" }42 43!llvm.module.flags = !{!0}44!0 = !{i32 7, !"PIC Level", i32 2}45