40 lines · plain
1;; Check that certain globals are in large sections under x86-64 medium code model (but not in other arches).2; RUN: opt %s -mtriple=x86_64-unknown-linux -passes=instrprof -S | FileCheck %s --check-prefixes=CHECK,X86643; RUN: opt %s -mtriple=ppc64-unknown-linux -passes=instrprof -S | FileCheck %s --check-prefixes=CHECK,PPC4 5@__profn_foo = private constant [3 x i8] c"foo"6 7define i32 @foo(ptr) {8 call void @llvm.instrprof.increment(ptr @__profn_foo, i64 12884901887, i32 1, i32 0)9 %2 = ptrtoint ptr %0 to i6410 call void @llvm.instrprof.value.profile(ptr @__profn_foo, i64 12884901887, i64 %2, i32 0, i32 0)11 %3 = tail call i32 %0()12 ret i32 %313}14 15; Function Attrs: nounwind16declare void @llvm.instrprof.increment(ptr, i64, i32, i32) #017 18; Function Attrs: nounwind19declare void @llvm.instrprof.value.profile(ptr, i64, i64, i32, i32) #020 21attributes #0 = { nounwind }22 23!llvm.module.flags = !{!0}24 25!0 = !{i32 1, !"Code Model", i32 3}26 27; CHECK: @__profc_foo =28; CHECK-NOT: code_model "large"29; CHECK: @__profvp_foo =30; X8664-SAME: code_model "large"31; PPC-NOT: code_model "large"32; CHECK: @__profd_foo =33; CHECK-NOT: code_model "large"34; CHECK: @__llvm_prf_vnodes =35; X8664-SAME: code_model "large"36; PPC-NOT: code_model "large"37; CHECK: @__llvm_prf_nm =38; X8664-SAME: code_model "large"39; PPC-NOT: code_model "large"40