Skip to content

Commit 319bd7f

Browse files
dhoekwatercopybara-github
authored andcommitted
Add testdata for a loop with cold entry and exit edges
PiperOrigin-RevId: 696893941
1 parent afd57b2 commit 319bd7f

File tree

2 files changed

+72
-0
lines changed

2 files changed

+72
-0
lines changed

propeller/testdata/BUILD

+1
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ exports_files([
3838
"hot_and_cold_landing_pads.protobuf",
3939
"llvm_function_samples.binary",
4040
"llvm_function_samples_perf.data",
41+
"loop_no_entry_no_exit.protobuf",
4142
"propeller_sample.protobuf",
4243
"propeller_sample_1.bin",
4344
"sample.bin",
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
## CFG Proto for a function consisting of a simple loop with cold entry and exit
2+
## edges.
3+
##
4+
## foo
5+
## |
6+
## |0
7+
## V
8+
## a.BB.foo <--+
9+
## | |
10+
## | |45
11+
## |40 |
12+
## | |
13+
## v |
14+
## aa.BB.foo ---+
15+
## |
16+
## | 0
17+
## v
18+
## raa.BB.foo
19+
20+
cfg {
21+
name: "foo"
22+
function_index: 0
23+
node {
24+
bb_id: 0
25+
size: 10
26+
out_edges {
27+
sink: {
28+
function_index: 0
29+
bb_index: 1
30+
}
31+
weight: 0
32+
kind: BRANCH_OR_FALLTHROUGH
33+
}
34+
}
35+
node {
36+
bb_id: 1
37+
size: 6
38+
out_edges {
39+
sink: {
40+
function_index: 0
41+
bb_index: 2
42+
}
43+
weight: 40
44+
kind: BRANCH_OR_FALLTHROUGH
45+
}
46+
}
47+
node {
48+
bb_id: 2
49+
size: 4
50+
out_edges {
51+
sink: {
52+
function_index: 0
53+
bb_index: 3
54+
}
55+
weight: 0
56+
kind: BRANCH_OR_FALLTHROUGH
57+
}
58+
out_edges {
59+
sink: {
60+
function_index: 0
61+
bb_index: 1
62+
}
63+
weight: 45
64+
kind: BRANCH_OR_FALLTHROUGH
65+
}
66+
}
67+
node {
68+
bb_id: 3
69+
size: 3
70+
}
71+
}

0 commit comments

Comments
 (0)