1; RUN: llc < %s -O0 -mcpu=generic -mtriple=i686-linux-gnu -relocation-model=pic | FileCheck %s 2; RUN: llc < %s -O0 -mcpu=generic -mtriple=i686-linux-gnu -fast-isel -relocation-model=pic | FileCheck %s 3; RUN: llc < %s -O0 -mcpu=generic -mtriple=x86_64-linux-gnu -relocation-model=pic | FileCheck %s 4; RUN: llc < %s -O0 -mcpu=generic -mtriple=x86_64-linux-gnu -fast-isel -relocation-model=pic | FileCheck %s 5 6; CHECK-LABEL: bar: 7; CHECK: call{{l|q}} foo{{$}} 8; CHECK: call{{l|q}} weak_odr_foo{{$}} 9; CHECK: call{{l|q}} weak_foo{{$}} 10; CHECK: call{{l|q}} internal_foo{{$}} 11; CHECK: call{{l|q}} ext_baz@PLT 12 13define weak void @weak_foo() { 14 ret void 15} 16 17define weak_odr void @weak_odr_foo() { 18 ret void 19} 20 21define internal void @internal_foo() { 22 ret void 23} 24 25declare i32 @ext_baz() 26 27define void @foo() { 28 ret void 29} 30 31define void @bar() { 32entry: 33 call void @foo() 34 call void @weak_odr_foo() 35 call void @weak_foo() 36 call void @internal_foo() 37 call i32 @ext_baz() 38 ret void 39} 40 41; -fpie for local global data tests should be added here 42 43!llvm.module.flags = !{!0, !1} 44!0 = !{i32 1, !"PIC Level", i32 1} 45!1 = !{i32 1, !"PIE Level", i32 1} 46