File tree 3 files changed +229
-0
lines changed
3 files changed +229
-0
lines changed Original file line number Diff line number Diff line change @@ -33,7 +33,9 @@ exports_files([
33
33
"all_cold_landing_pads.protobuf" ,
34
34
"bimodal_sample.bin" ,
35
35
"bimodal_sample.x.bin" ,
36
+ "call_from_simple_loop.protobuf" ,
36
37
"clang_v0_labels.binary" ,
38
+ "hot_and_cold_landing_pads.protobuf" ,
37
39
"llvm_function_samples.binary" ,
38
40
"llvm_function_samples_perf.data" ,
39
41
"propeller_sample.protobuf" ,
Original file line number Diff line number Diff line change
1
+ ## CFG consisting of a function calling another function in a simple loop.
2
+ ##
3
+ ## foo <------- baz
4
+ ## | 100
5
+ ## 5 |
6
+ ## |
7
+ ## v 100
8
+ ## +---> foo.1 -------> bar
9
+ ## | |
10
+ ## | 100 |100
11
+ ## | |
12
+ ## | v
13
+ ## +--- foo.2
14
+ ##
15
+
16
+ cfg {
17
+ name: "foo"
18
+ function_index: 1
19
+ node {
20
+ bb_id: 0
21
+ size: 10
22
+ out_edges {
23
+ sink : {
24
+ function_index: 1
25
+ bb_index: 1
26
+ }
27
+ weight: 5
28
+ kind: BRANCH_OR_FALLTHROUGH
29
+ }
30
+ }
31
+ node {
32
+ bb_id: 1
33
+ size: 4
34
+ out_edges {
35
+ sink : {
36
+ function_index: 1
37
+ bb_index: 2
38
+ }
39
+ weight: 100
40
+ kind: BRANCH_OR_FALLTHROUGH
41
+ }
42
+ out_edges {
43
+ sink : {
44
+ function_index: 2
45
+ bb_index: 0
46
+ }
47
+ weight: 100
48
+ kind: CALL
49
+ }
50
+ }
51
+ node {
52
+ bb_id: 2
53
+ size: 6
54
+ out_edges {
55
+ sink : {
56
+ function_index: 1
57
+ bb_index: 1
58
+ }
59
+ weight: 100
60
+ kind: BRANCH_OR_FALLTHROUGH
61
+ }
62
+ }
63
+ }
64
+ cfg {
65
+ name: "bar"
66
+ function_index: 2
67
+ node {
68
+ bb_id: 0
69
+ size: 2
70
+ }
71
+ }
72
+ cfg {
73
+ name: "baz"
74
+ function_index: 3
75
+ node {
76
+ bb_id: 0
77
+ size: 6
78
+ out_edges {
79
+ sink : {
80
+ function_index: 1
81
+ bb_index: 0
82
+ }
83
+ weight: 100
84
+ kind: CALL
85
+ }
86
+ }
87
+ }
Original file line number Diff line number Diff line change
1
+ ## CFG Proto for two functions: Function foo has two exception handling landing
2
+ ## pads. One is cold, the other is hot.
3
+ ##
4
+ ##
5
+ ## 10
6
+ ## +-----------------+
7
+ ## | |
8
+ ## v 20 |
9
+ ## foo -------------> bar
10
+ ## / \
11
+ ## 10 / \ 10
12
+ ## v v
13
+ ## foo.1 foo.2 ----+
14
+ ## / \ |
15
+ ## 10 / \ 0 |
16
+ ## v v |
17
+ ## foo.4 foo.3 [eh pad] |
18
+ ## \ / | 10
19
+ ## 10 \ /0 |
20
+ ## \ / |
21
+ ## v v |
22
+ ## foo.5 <--------------+
23
+ ##
24
+
25
+ cfg {
26
+ name: "foo"
27
+ function_index: 10
28
+ node {
29
+ bb_id: 0
30
+ size: 10
31
+ out_edges {
32
+ sink: {
33
+ function_index: 10
34
+ bb_index: 1
35
+ }
36
+ weight: 10
37
+ kind: BRANCH_OR_FALLTHROUGH
38
+ }
39
+ out_edges {
40
+ sink: {
41
+ function_index: 10
42
+ bb_index: 2
43
+ }
44
+ weight: 10
45
+ kind: BRANCH_OR_FALLTHROUGH
46
+ }
47
+ out_edges {
48
+ sink: {
49
+ function_index: 20
50
+ bb_index: 0
51
+ }
52
+ weight: 20
53
+ kind: CALL
54
+ }
55
+ }
56
+ node {
57
+ bb_id: 1
58
+ size: 10
59
+ out_edges {
60
+ sink: {
61
+ function_index: 10
62
+ bb_index: 4
63
+ }
64
+ weight: 10
65
+ kind: BRANCH_OR_FALLTHROUGH
66
+ }
67
+ out_edges {
68
+ sink: {
69
+ function_index: 10
70
+ bb_index: 3
71
+ }
72
+ weight: 0
73
+ kind: BRANCH_OR_FALLTHROUGH
74
+ }
75
+ }
76
+ node {
77
+ bb_id: 2
78
+ size: 10
79
+ metadata {
80
+ is_landing_pad : true
81
+ }
82
+ out_edges {
83
+ sink: {
84
+ function_index: 10
85
+ bb_index: 5
86
+ }
87
+ weight: 10
88
+ kind: BRANCH_OR_FALLTHROUGH
89
+ }
90
+ }
91
+ node {
92
+ bb_id: 3
93
+ size: 10
94
+ metadata {
95
+ is_landing_pad: true
96
+ }
97
+ out_edges {
98
+ sink: {
99
+ function_index: 10
100
+ bb_index: 5
101
+ }
102
+ weight: 0
103
+ kind: BRANCH_OR_FALLTHROUGH
104
+ }
105
+ }
106
+ node {
107
+ bb_id: 4
108
+ size: 10
109
+ out_edges {
110
+ sink: {
111
+ function_index: 10
112
+ bb_index: 5
113
+ }
114
+ weight: 10
115
+ kind: BRANCH_OR_FALLTHROUGH
116
+ }
117
+ }
118
+ node {
119
+ bb_id: 5
120
+ size: 10
121
+ }
122
+ }
123
+
124
+ cfg {
125
+ name: "bar"
126
+ function_index: 20
127
+ node {
128
+ bb_id: 0
129
+ size: 10
130
+ out_edges {
131
+ sink: {
132
+ function_index: 10
133
+ bb_index: 0
134
+ }
135
+ weight: 10
136
+ kind: RETURN
137
+ }
138
+ }
139
+ }
140
+
You can’t perform that action at this time.
0 commit comments