99declare void @bar ()
1010
1111;.
12- ; INSTRUMENT: @__profn_foo = private constant [3 x i8] c"foo"
13- ; INSTRUMENT: @__profn_an_entrypoint = private constant [13 x i8] c"an_entrypoint"
14- ; INSTRUMENT: @__profn_another_entrypoint_no_callees = private constant [29 x i8] c"another_entrypoint_no_callees"
15- ; INSTRUMENT: @__profn_simple = private constant [6 x i8] c"simple"
16- ; INSTRUMENT: @__profn_no_callsites = private constant [12 x i8] c"no_callsites"
17- ; INSTRUMENT: @__profn_no_counters = private constant [11 x i8] c"no_counters"
18- ;.
19- ; LOWERING: @__profn_foo = private constant [3 x i8] c"foo"
20- ; LOWERING: @__profn_an_entrypoint = private constant [13 x i8] c"an_entrypoint"
21- ; LOWERING: @__profn_another_entrypoint_no_callees = private constant [29 x i8] c"another_entrypoint_no_callees"
22- ; LOWERING: @__profn_simple = private constant [6 x i8] c"simple"
23- ; LOWERING: @__profn_no_callsites = private constant [12 x i8] c"no_callsites"
24- ; LOWERING: @__profn_no_counters = private constant [11 x i8] c"no_counters"
2512; LOWERING: @an_entrypoint_ctx_root = global { ptr, ptr, ptr, i8 } zeroinitializer
2613; LOWERING: @another_entrypoint_no_callees_ctx_root = global { ptr, ptr, ptr, i8 } zeroinitializer
2714; LOWERING: @__llvm_ctx_profile_callsite = external hidden thread_local global ptr
@@ -30,16 +17,16 @@ declare void @bar()
3017define void @foo (i32 %a , ptr %fct ) {
3118; INSTRUMENT-LABEL: define void @foo(
3219; INSTRUMENT-SAME: i32 [[A:%.*]], ptr [[FCT:%.*]]) {
33- ; INSTRUMENT-NEXT: call void @llvm.instrprof.increment(ptr @__profn_foo , i64 728453322856651412, i32 2, i32 0)
20+ ; INSTRUMENT-NEXT: call void @llvm.instrprof.increment(ptr @foo , i64 728453322856651412, i32 2, i32 0)
3421; INSTRUMENT-NEXT: [[T:%.*]] = icmp eq i32 [[A]], 0
3522; INSTRUMENT-NEXT: br i1 [[T]], label [[YES:%.*]], label [[NO:%.*]]
3623; INSTRUMENT: yes:
37- ; INSTRUMENT-NEXT: call void @llvm.instrprof.increment(ptr @__profn_foo , i64 728453322856651412, i32 2, i32 1)
38- ; INSTRUMENT-NEXT: call void @llvm.instrprof.callsite(ptr @__profn_foo , i64 728453322856651412, i32 2, i32 0, ptr [[FCT]])
24+ ; INSTRUMENT-NEXT: call void @llvm.instrprof.increment(ptr @foo , i64 728453322856651412, i32 2, i32 1)
25+ ; INSTRUMENT-NEXT: call void @llvm.instrprof.callsite(ptr @foo , i64 728453322856651412, i32 2, i32 0, ptr [[FCT]])
3926; INSTRUMENT-NEXT: call void [[FCT]](i32 [[A]])
4027; INSTRUMENT-NEXT: br label [[EXIT:%.*]]
4128; INSTRUMENT: no:
42- ; INSTRUMENT-NEXT: call void @llvm.instrprof.callsite(ptr @__profn_foo , i64 728453322856651412, i32 2, i32 1, ptr @bar)
29+ ; INSTRUMENT-NEXT: call void @llvm.instrprof.callsite(ptr @foo , i64 728453322856651412, i32 2, i32 1, ptr @bar)
4330; INSTRUMENT-NEXT: call void @bar()
4431; INSTRUMENT-NEXT: br label [[EXIT]]
4532; INSTRUMENT: exit:
@@ -92,12 +79,12 @@ exit:
9279define void @an_entrypoint (i32 %a ) {
9380; INSTRUMENT-LABEL: define void @an_entrypoint(
9481; INSTRUMENT-SAME: i32 [[A:%.*]]) {
95- ; INSTRUMENT-NEXT: call void @llvm.instrprof.increment(ptr @__profn_an_entrypoint , i64 784007058953177093, i32 2, i32 0)
82+ ; INSTRUMENT-NEXT: call void @llvm.instrprof.increment(ptr @an_entrypoint , i64 784007058953177093, i32 2, i32 0)
9683; INSTRUMENT-NEXT: [[T:%.*]] = icmp eq i32 [[A]], 0
9784; INSTRUMENT-NEXT: br i1 [[T]], label [[YES:%.*]], label [[NO:%.*]]
9885; INSTRUMENT: yes:
99- ; INSTRUMENT-NEXT: call void @llvm.instrprof.increment(ptr @__profn_an_entrypoint , i64 784007058953177093, i32 2, i32 1)
100- ; INSTRUMENT-NEXT: call void @llvm.instrprof.callsite(ptr @__profn_an_entrypoint , i64 784007058953177093, i32 1, i32 0, ptr @foo)
86+ ; INSTRUMENT-NEXT: call void @llvm.instrprof.increment(ptr @an_entrypoint , i64 784007058953177093, i32 2, i32 1)
87+ ; INSTRUMENT-NEXT: call void @llvm.instrprof.callsite(ptr @an_entrypoint , i64 784007058953177093, i32 1, i32 0, ptr @foo)
10188; INSTRUMENT-NEXT: call void @foo(i32 1, ptr null)
10289; INSTRUMENT-NEXT: ret void
10390; INSTRUMENT: no:
@@ -144,11 +131,11 @@ no:
144131define void @another_entrypoint_no_callees (i32 %a ) {
145132; INSTRUMENT-LABEL: define void @another_entrypoint_no_callees(
146133; INSTRUMENT-SAME: i32 [[A:%.*]]) {
147- ; INSTRUMENT-NEXT: call void @llvm.instrprof.increment(ptr @__profn_another_entrypoint_no_callees , i64 784007058953177093, i32 2, i32 0)
134+ ; INSTRUMENT-NEXT: call void @llvm.instrprof.increment(ptr @another_entrypoint_no_callees , i64 784007058953177093, i32 2, i32 0)
148135; INSTRUMENT-NEXT: [[T:%.*]] = icmp eq i32 [[A]], 0
149136; INSTRUMENT-NEXT: br i1 [[T]], label [[YES:%.*]], label [[NO:%.*]]
150137; INSTRUMENT: yes:
151- ; INSTRUMENT-NEXT: call void @llvm.instrprof.increment(ptr @__profn_another_entrypoint_no_callees , i64 784007058953177093, i32 2, i32 1)
138+ ; INSTRUMENT-NEXT: call void @llvm.instrprof.increment(ptr @another_entrypoint_no_callees , i64 784007058953177093, i32 2, i32 1)
152139; INSTRUMENT-NEXT: ret void
153140; INSTRUMENT: no:
154141; INSTRUMENT-NEXT: ret void
184171define void @simple (i32 %a ) {
185172; INSTRUMENT-LABEL: define void @simple(
186173; INSTRUMENT-SAME: i32 [[A:%.*]]) {
187- ; INSTRUMENT-NEXT: call void @llvm.instrprof.increment(ptr @__profn_simple , i64 742261418966908927, i32 1, i32 0)
174+ ; INSTRUMENT-NEXT: call void @llvm.instrprof.increment(ptr @simple , i64 742261418966908927, i32 1, i32 0)
188175; INSTRUMENT-NEXT: ret void
189176;
190177; LOWERING-LABEL: define void @simple(
@@ -202,11 +189,11 @@ define void @simple(i32 %a) {
202189define i32 @no_callsites (i32 %a ) {
203190; INSTRUMENT-LABEL: define i32 @no_callsites(
204191; INSTRUMENT-SAME: i32 [[A:%.*]]) {
205- ; INSTRUMENT-NEXT: call void @llvm.instrprof.increment(ptr @__profn_no_callsites , i64 784007058953177093, i32 2, i32 0)
192+ ; INSTRUMENT-NEXT: call void @llvm.instrprof.increment(ptr @no_callsites , i64 784007058953177093, i32 2, i32 0)
206193; INSTRUMENT-NEXT: [[C:%.*]] = icmp eq i32 [[A]], 0
207194; INSTRUMENT-NEXT: br i1 [[C]], label [[YES:%.*]], label [[NO:%.*]]
208195; INSTRUMENT: yes:
209- ; INSTRUMENT-NEXT: call void @llvm.instrprof.increment(ptr @__profn_no_callsites , i64 784007058953177093, i32 2, i32 1)
196+ ; INSTRUMENT-NEXT: call void @llvm.instrprof.increment(ptr @no_callsites , i64 784007058953177093, i32 2, i32 1)
210197; INSTRUMENT-NEXT: ret i32 1
211198; INSTRUMENT: no:
212199; INSTRUMENT-NEXT: ret i32 0
238225
239226define void @no_counters () {
240227; INSTRUMENT-LABEL: define void @no_counters() {
241- ; INSTRUMENT-NEXT: call void @llvm.instrprof.increment(ptr @__profn_no_counters , i64 742261418966908927, i32 1, i32 0)
242- ; INSTRUMENT-NEXT: call void @llvm.instrprof.callsite(ptr @__profn_no_counters , i64 742261418966908927, i32 1, i32 0, ptr @bar)
228+ ; INSTRUMENT-NEXT: call void @llvm.instrprof.increment(ptr @no_counters , i64 742261418966908927, i32 1, i32 0)
229+ ; INSTRUMENT-NEXT: call void @llvm.instrprof.callsite(ptr @no_counters , i64 742261418966908927, i32 1, i32 0, ptr @bar)
243230; INSTRUMENT-NEXT: call void @bar()
244231; INSTRUMENT-NEXT: ret void
245232;
0 commit comments