2020-04-15 18:28:08 +03:00
|
|
|
# RUN: llvm-profdata show -ic-targets -all-functions %s | FileCheck %s --check-prefixes=ICTXT,ICSUM
|
2015-12-14 18:44:01 +00:00
|
|
|
# RUN: llvm-profdata show -ic-targets -counts -text -all-functions %s | FileCheck %s --check-prefix=ICTEXT
|
|
|
|
# RUN: llvm-profdata merge -o %t.profdata %s
|
2020-04-15 18:28:08 +03:00
|
|
|
# RUN: llvm-profdata show -ic-targets -all-functions %t.profdata | FileCheck %s --check-prefixes=IC,ICSUM
|
2015-12-14 18:44:01 +00:00
|
|
|
|
|
|
|
foo
|
|
|
|
# Func Hash:
|
|
|
|
10
|
|
|
|
# Num Counters:
|
|
|
|
2
|
|
|
|
# Counter Values:
|
|
|
|
999000
|
|
|
|
359800
|
|
|
|
|
|
|
|
foo2
|
|
|
|
# Func Hash:
|
|
|
|
10
|
|
|
|
# Num Counters:
|
|
|
|
2
|
|
|
|
# Counter Values:
|
|
|
|
1001000
|
|
|
|
360200
|
|
|
|
|
|
|
|
main
|
|
|
|
# Func Hash:
|
|
|
|
16650
|
|
|
|
# Num Counters:
|
|
|
|
4
|
|
|
|
# Counter Values:
|
|
|
|
2
|
|
|
|
2000
|
|
|
|
2000000
|
|
|
|
999000
|
|
|
|
# NumValueKinds
|
|
|
|
1
|
|
|
|
# Value Kind IPVK_IndirectCallTarget
|
|
|
|
0
|
|
|
|
# NumSites
|
|
|
|
3
|
|
|
|
# Values for each site
|
|
|
|
0
|
|
|
|
2
|
|
|
|
foo:100
|
|
|
|
foo2:1000
|
|
|
|
1
|
|
|
|
foo2:20000
|
|
|
|
|
2016-01-08 05:45:21 +00:00
|
|
|
#ICTXT: Indirect Call Site Count: 3
|
2017-03-09 19:03:57 +00:00
|
|
|
#ICTXT-NEXT: Indirect Target Results:
|
2019-01-08 22:41:48 +00:00
|
|
|
#ICTXT-NEXT: [ 1, foo, 100 ] (9.09%)
|
|
|
|
#ICTXT-NEXT: [ 1, foo2, 1000 ] (90.91%)
|
|
|
|
#ICTXT-NEXT: [ 2, foo2, 20000 ] (100.00%)
|
2016-01-08 05:45:21 +00:00
|
|
|
|
2015-12-14 18:44:01 +00:00
|
|
|
#IC: Indirect Call Site Count: 3
|
2017-03-09 19:03:57 +00:00
|
|
|
#IC-NEXT: Indirect Target Results:
|
2015-12-14 18:44:01 +00:00
|
|
|
#IC-NEXT: [ 1, foo2, 1000 ]
|
2016-01-08 05:45:21 +00:00
|
|
|
#IC-NEXT: [ 1, foo, 100 ]
|
2015-12-14 18:44:01 +00:00
|
|
|
#IC-NEXT: [ 2, foo2, 20000 ]
|
|
|
|
|
|
|
|
#ICTEXT: foo:100
|
|
|
|
#ICTEXT-NEXT: foo2:1000
|
|
|
|
#ICTEXT-NEXT: 1
|
|
|
|
#ICTEXT-NEXT: foo2:20000
|
2016-05-23 16:36:11 +00:00
|
|
|
#
|
|
|
|
|
2017-03-03 21:56:34 +00:00
|
|
|
bar
|
|
|
|
# Func Hash:
|
|
|
|
10
|
|
|
|
# Num Counters:
|
|
|
|
2
|
|
|
|
# Counter Values:
|
|
|
|
999000
|
|
|
|
359800
|
|
|
|
|
2017-03-09 19:03:57 +00:00
|
|
|
#ICSUM: Statistics for indirect call sites profile:
|
|
|
|
#ICSUM: Total number of sites: 3
|
|
|
|
#ICSUM: Total number of sites with values: 2
|
|
|
|
#ICSUM: Total number of profiled values: 3
|
2016-09-20 21:04:22 +00:00
|
|
|
#ICSUM: NumTargets, SiteCount
|
2020-04-02 16:28:32 -06:00
|
|
|
#ICSUM: 1, 1
|
|
|
|
#ICSUM: 2, 1
|