[FIR] Introduce new algorithm for building CFG for declarations

This commit is contained in:
Dmitriy Novozhilov
2020-06-05 15:47:57 +03:00
parent 950bbfe3a5
commit 87859b0faa
95 changed files with 16070 additions and 13199 deletions
@@ -12,10 +12,10 @@ digraph boundSmartcasts_kt {
subgraph cluster_1 {
color=red
2 [label="Enter class A" style="filled" fillcolor=red];
3 [label="Exit class A" style="filled" fillcolor=red];
3 [label="Enter class A" style="filled" fillcolor=red];
2 [label="Exit class A" style="filled" fillcolor=red];
}
2 -> {3} [color=green];
3 -> {2} [color=green];
subgraph cluster_2 {
color=red
@@ -26,410 +26,423 @@ digraph boundSmartcasts_kt {
subgraph cluster_3 {
color=red
6 [label="Enter class B" style="filled" fillcolor=red];
7 [label="Exit class B" style="filled" fillcolor=red];
7 [label="Enter class B" style="filled" fillcolor=red];
6 [label="Exit class B" style="filled" fillcolor=red];
}
6 -> {7} [color=green];
7 -> {6} [color=green];
subgraph cluster_4 {
color=red
8 [label="Enter function test_1" style="filled" fillcolor=red];
10 [label="Access variable R|<local>/x|"];
11 [label="Variable declaration: lval y: R|kotlin/Any|"];
subgraph cluster_5 {
color=blue
12 [label="Enter when"];
10 [label="Enter block"];
11 [label="Access variable R|<local>/x|"];
12 [label="Variable declaration: lval y: R|kotlin/Any|"];
subgraph cluster_6 {
color=blue
14 [label="Enter when branch condition "];
15 [label="Access variable R|<local>/x|"];
16 [label="Type operator: (R|<local>/x| is R|A|)"];
17 [label="Exit when branch condition"];
13 [label="Enter when"];
subgraph cluster_7 {
color=blue
15 [label="Enter when branch condition "];
16 [label="Access variable R|<local>/x|"];
17 [label="Type operator: (R|<local>/x| is R|A|)"];
18 [label="Exit when branch condition"];
}
27 [label="Synthetic else branch"];
19 [label="Enter when branch result"];
subgraph cluster_8 {
color=blue
20 [label="Enter block"];
21 [label="Access variable R|<local>/x|"];
22 [label="Function call: R|<local>/x|.R|/A.foo|()"];
23 [label="Access variable R|<local>/y|"];
24 [label="Function call: R|<local>/y|.R|/A.foo|()"];
25 [label="Exit block"];
}
26 [label="Exit when branch result"];
14 [label="Exit when"];
}
26 [label="Synthetic else branch"];
18 [label="Enter when branch result"];
subgraph cluster_7 {
color=blue
19 [label="Enter block"];
20 [label="Access variable R|<local>/x|"];
21 [label="Function call: R|<local>/x|.R|/A.foo|()"];
22 [label="Access variable R|<local>/y|"];
23 [label="Function call: R|<local>/y|.R|/A.foo|()"];
24 [label="Exit block"];
}
25 [label="Exit when branch result"];
13 [label="Exit when"];
28 [label="Exit block"];
}
9 [label="Exit function test_1" style="filled" fillcolor=red];
}
8 -> {10};
10 -> {11};
11 -> {12};
12 -> {14};
13 -> {9};
14 -> {15};
12 -> {13};
13 -> {15};
14 -> {28};
15 -> {16};
16 -> {17};
17 -> {18 26};
18 -> {19};
17 -> {18};
18 -> {19 27};
19 -> {20};
20 -> {21};
21 -> {22};
22 -> {23};
23 -> {24};
24 -> {25};
25 -> {13};
26 -> {13};
25 -> {26};
26 -> {14};
27 -> {14};
28 -> {9};
subgraph cluster_8 {
subgraph cluster_9 {
color=red
27 [label="Enter function test_2" style="filled" fillcolor=red];
29 [label="Access variable R|<local>/x|"];
30 [label="Variable declaration: lval y: R|kotlin/Any|"];
subgraph cluster_9 {
29 [label="Enter function test_2" style="filled" fillcolor=red];
subgraph cluster_10 {
color=blue
31 [label="Enter when"];
subgraph cluster_10 {
color=blue
33 [label="Enter when branch condition "];
34 [label="Access variable R|<local>/y|"];
35 [label="Type operator: (R|<local>/y| is R|A|)"];
36 [label="Exit when branch condition"];
}
45 [label="Synthetic else branch"];
37 [label="Enter when branch result"];
31 [label="Enter block"];
32 [label="Access variable R|<local>/x|"];
33 [label="Variable declaration: lval y: R|kotlin/Any|"];
subgraph cluster_11 {
color=blue
38 [label="Enter block"];
39 [label="Access variable R|<local>/x|"];
40 [label="Function call: R|<local>/x|.R|/A.foo|()"];
41 [label="Access variable R|<local>/y|"];
42 [label="Function call: R|<local>/y|.R|/A.foo|()"];
43 [label="Exit block"];
34 [label="Enter when"];
subgraph cluster_12 {
color=blue
36 [label="Enter when branch condition "];
37 [label="Access variable R|<local>/y|"];
38 [label="Type operator: (R|<local>/y| is R|A|)"];
39 [label="Exit when branch condition"];
}
48 [label="Synthetic else branch"];
40 [label="Enter when branch result"];
subgraph cluster_13 {
color=blue
41 [label="Enter block"];
42 [label="Access variable R|<local>/x|"];
43 [label="Function call: R|<local>/x|.R|/A.foo|()"];
44 [label="Access variable R|<local>/y|"];
45 [label="Function call: R|<local>/y|.R|/A.foo|()"];
46 [label="Exit block"];
}
47 [label="Exit when branch result"];
35 [label="Exit when"];
}
44 [label="Exit when branch result"];
32 [label="Exit when"];
49 [label="Exit block"];
}
28 [label="Exit function test_2" style="filled" fillcolor=red];
30 [label="Exit function test_2" style="filled" fillcolor=red];
}
27 -> {29};
29 -> {30};
30 -> {31};
31 -> {33};
32 -> {28};
29 -> {31};
31 -> {32};
32 -> {33};
33 -> {34};
34 -> {35};
35 -> {36};
36 -> {37 45};
34 -> {36};
35 -> {49};
36 -> {37};
37 -> {38};
38 -> {39};
39 -> {40};
39 -> {40 48};
40 -> {41};
41 -> {42};
42 -> {43};
43 -> {44};
44 -> {32};
45 -> {32};
44 -> {45};
45 -> {46};
46 -> {47};
47 -> {35};
48 -> {35};
49 -> {30};
subgraph cluster_12 {
subgraph cluster_14 {
color=red
46 [label="Enter function test_3" style="filled" fillcolor=red];
48 [label="Access variable R|<local>/x|"];
49 [label="Variable declaration: lvar z: R|kotlin/Any|"];
subgraph cluster_13 {
50 [label="Enter function test_3" style="filled" fillcolor=red];
subgraph cluster_15 {
color=blue
50 [label="Enter when"];
subgraph cluster_14 {
52 [label="Enter block"];
53 [label="Access variable R|<local>/x|"];
54 [label="Variable declaration: lvar z: R|kotlin/Any|"];
subgraph cluster_16 {
color=blue
52 [label="Enter when branch condition "];
53 [label="Access variable R|<local>/x|"];
54 [label="Type operator: (R|<local>/x| is R|A|)"];
55 [label="Exit when branch condition"];
55 [label="Enter when"];
subgraph cluster_17 {
color=blue
57 [label="Enter when branch condition "];
58 [label="Access variable R|<local>/x|"];
59 [label="Type operator: (R|<local>/x| is R|A|)"];
60 [label="Exit when branch condition"];
}
67 [label="Synthetic else branch"];
61 [label="Enter when branch result"];
subgraph cluster_18 {
color=blue
62 [label="Enter block"];
63 [label="Access variable R|<local>/z|"];
64 [label="Function call: R|<local>/z|.R|/A.foo|()"];
65 [label="Exit block"];
}
66 [label="Exit when branch result"];
56 [label="Exit when"];
}
62 [label="Synthetic else branch"];
56 [label="Enter when branch result"];
subgraph cluster_15 {
68 [label="Access variable R|<local>/y|"];
69 [label="Assignment: R|<local>/z|"];
subgraph cluster_19 {
color=blue
57 [label="Enter block"];
58 [label="Access variable R|<local>/z|"];
59 [label="Function call: R|<local>/z|.R|/A.foo|()"];
60 [label="Exit block"];
70 [label="Enter when"];
subgraph cluster_20 {
color=blue
72 [label="Enter when branch condition "];
73 [label="Access variable R|<local>/y|"];
74 [label="Type operator: (R|<local>/y| is R|B|)"];
75 [label="Exit when branch condition"];
}
84 [label="Synthetic else branch"];
76 [label="Enter when branch result"];
subgraph cluster_21 {
color=blue
77 [label="Enter block"];
78 [label="Access variable R|<local>/z|"];
79 [label="Function call: R|<local>/z|.<Unresolved name: foo>#()"];
80 [label="Access variable R|<local>/z|"];
81 [label="Function call: R|<local>/z|.R|/B.bar|()"];
82 [label="Exit block"];
}
83 [label="Exit when branch result"];
71 [label="Exit when"];
}
61 [label="Exit when branch result"];
51 [label="Exit when"];
85 [label="Exit block"];
}
63 [label="Access variable R|<local>/y|"];
64 [label="Assignment: R|<local>/z|"];
subgraph cluster_16 {
color=blue
65 [label="Enter when"];
subgraph cluster_17 {
color=blue
67 [label="Enter when branch condition "];
68 [label="Access variable R|<local>/y|"];
69 [label="Type operator: (R|<local>/y| is R|B|)"];
70 [label="Exit when branch condition"];
}
79 [label="Synthetic else branch"];
71 [label="Enter when branch result"];
subgraph cluster_18 {
color=blue
72 [label="Enter block"];
73 [label="Access variable R|<local>/z|"];
74 [label="Function call: R|<local>/z|.<Unresolved name: foo>#()"];
75 [label="Access variable R|<local>/z|"];
76 [label="Function call: R|<local>/z|.R|/B.bar|()"];
77 [label="Exit block"];
}
78 [label="Exit when branch result"];
66 [label="Exit when"];
}
47 [label="Exit function test_3" style="filled" fillcolor=red];
51 [label="Exit function test_3" style="filled" fillcolor=red];
}
46 -> {48};
48 -> {49};
49 -> {50};
50 -> {52};
51 -> {63};
52 -> {53};
53 -> {54};
54 -> {55};
55 -> {56 62};
56 -> {57};
55 -> {57};
56 -> {68};
57 -> {58};
58 -> {59};
59 -> {60};
60 -> {61};
61 -> {51};
62 -> {51};
60 -> {61 67};
61 -> {62};
62 -> {63};
63 -> {64};
64 -> {65};
65 -> {67};
66 -> {47};
67 -> {68};
65 -> {66};
66 -> {56};
67 -> {56};
68 -> {69};
69 -> {70};
70 -> {71 79};
71 -> {72};
70 -> {72};
71 -> {85};
72 -> {73};
73 -> {74};
74 -> {75};
75 -> {76};
75 -> {76 84};
76 -> {77};
77 -> {78};
78 -> {66};
79 -> {66};
subgraph cluster_19 {
color=red
80 [label="Enter function test_4" style="filled" fillcolor=red];
82 [label="Const: Int(1)"];
83 [label="Variable declaration: lvar x: R|kotlin/Any|"];
84 [label="Access variable R|<local>/x|"];
85 [label="Type operator: (R|<local>/x| as R|kotlin/Int|)"];
86 [label="Access variable R|<local>/x|"];
87 [label="Function call: R|<local>/x|.R|kotlin/Int.inc|()"];
88 [label="Access variable R|<local>/y|"];
89 [label="Assignment: R|<local>/x|"];
90 [label="Access variable R|<local>/x|"];
91 [label="Function call: R|<local>/x|.<Unresolved name: inc>#()"];
subgraph cluster_20 {
color=blue
92 [label="Enter when"];
subgraph cluster_21 {
color=blue
94 [label="Enter when branch condition "];
95 [label="Access variable R|<local>/y|"];
96 [label="Type operator: (R|<local>/y| is R|A|)"];
97 [label="Exit when branch condition"];
}
106 [label="Synthetic else branch"];
98 [label="Enter when branch result"];
subgraph cluster_22 {
color=blue
99 [label="Enter block"];
100 [label="Access variable R|<local>/x|"];
101 [label="Function call: R|<local>/x|.R|/A.foo|()"];
102 [label="Access variable R|<local>/y|"];
103 [label="Function call: R|<local>/y|.R|/A.foo|()"];
104 [label="Exit block"];
}
105 [label="Exit when branch result"];
93 [label="Exit when"];
}
81 [label="Exit function test_4" style="filled" fillcolor=red];
}
80 -> {82};
78 -> {79};
79 -> {80};
80 -> {81};
81 -> {82};
82 -> {83};
83 -> {84};
84 -> {85};
85 -> {86};
86 -> {87};
87 -> {88};
83 -> {71};
84 -> {71};
85 -> {51};
subgraph cluster_22 {
color=red
86 [label="Enter function test_4" style="filled" fillcolor=red];
subgraph cluster_23 {
color=blue
88 [label="Enter block"];
89 [label="Const: Int(1)"];
90 [label="Variable declaration: lvar x: R|kotlin/Any|"];
91 [label="Access variable R|<local>/x|"];
92 [label="Type operator: (R|<local>/x| as R|kotlin/Int|)"];
93 [label="Access variable R|<local>/x|"];
94 [label="Function call: R|<local>/x|.R|kotlin/Int.inc|()"];
95 [label="Access variable R|<local>/y|"];
96 [label="Assignment: R|<local>/x|"];
97 [label="Access variable R|<local>/x|"];
98 [label="Function call: R|<local>/x|.<Unresolved name: inc>#()"];
subgraph cluster_24 {
color=blue
99 [label="Enter when"];
subgraph cluster_25 {
color=blue
101 [label="Enter when branch condition "];
102 [label="Access variable R|<local>/y|"];
103 [label="Type operator: (R|<local>/y| is R|A|)"];
104 [label="Exit when branch condition"];
}
113 [label="Synthetic else branch"];
105 [label="Enter when branch result"];
subgraph cluster_26 {
color=blue
106 [label="Enter block"];
107 [label="Access variable R|<local>/x|"];
108 [label="Function call: R|<local>/x|.R|/A.foo|()"];
109 [label="Access variable R|<local>/y|"];
110 [label="Function call: R|<local>/y|.R|/A.foo|()"];
111 [label="Exit block"];
}
112 [label="Exit when branch result"];
100 [label="Exit when"];
}
114 [label="Exit block"];
}
87 [label="Exit function test_4" style="filled" fillcolor=red];
}
86 -> {88};
88 -> {89};
89 -> {90};
90 -> {91};
91 -> {92};
92 -> {94};
93 -> {81};
92 -> {93};
93 -> {94};
94 -> {95};
95 -> {96};
96 -> {97};
97 -> {98 106};
97 -> {98};
98 -> {99};
99 -> {100};
100 -> {101};
99 -> {101};
100 -> {114};
101 -> {102};
102 -> {103};
103 -> {104};
104 -> {105};
105 -> {93};
106 -> {93};
subgraph cluster_23 {
color=red
107 [label="Enter function <init>" style="filled" fillcolor=red];
109 [label="Delegated constructor call: super<R|kotlin/Any|>()"];
108 [label="Exit function <init>" style="filled" fillcolor=red];
}
107 -> {109};
109 -> {108};
subgraph cluster_24 {
color=red
115 [label="Enter class D" style="filled" fillcolor=red];
subgraph cluster_25 {
color=blue
110 [label="Enter function getter" style="filled" fillcolor=red];
111 [label="Exit function getter" style="filled" fillcolor=red];
}
subgraph cluster_26 {
color=blue
112 [label="Enter property" style="filled" fillcolor=red];
114 [label="Access variable R|<local>/any|"];
113 [label="Exit property" style="filled" fillcolor=red];
}
116 [label="Exit class D" style="filled" fillcolor=red];
}
115 -> {112} [color=green];
112 -> {114};
113 -> {116} [color=green];
114 -> {113};
104 -> {105 113};
105 -> {106};
106 -> {107};
107 -> {108};
108 -> {109};
109 -> {110};
110 -> {111};
111 -> {112};
112 -> {100};
113 -> {100};
114 -> {87};
subgraph cluster_27 {
color=red
117 [label="Enter function baz" style="filled" fillcolor=red];
118 [label="Exit function baz" style="filled" fillcolor=red];
115 [label="Enter function <init>" style="filled" fillcolor=red];
117 [label="Delegated constructor call: super<R|kotlin/Any|>()"];
116 [label="Exit function <init>" style="filled" fillcolor=red];
}
117 -> {118};
115 -> {117};
117 -> {116};
subgraph cluster_28 {
color=red
119 [label="Enter function test_5" style="filled" fillcolor=red];
subgraph cluster_29 {
color=blue
121 [label="Enter when"];
123 [label="Access variable R|<local>/d|"];
124 [label="Access variable R|/D.any|"];
125 [label="Variable declaration: lval <elvis>: R|kotlin/Any?|"];
subgraph cluster_30 {
color=blue
126 [label="Enter when branch condition "];
127 [label="Const: Null(null)"];
128 [label="Operator =="];
129 [label="Exit when branch condition"];
}
subgraph cluster_31 {
color=blue
136 [label="Enter when branch condition else"];
137 [label="Exit when branch condition"];
}
138 [label="Enter when branch result"];
subgraph cluster_32 {
color=blue
139 [label="Enter block"];
140 [label="Access variable R|<local>/<elvis>|"];
141 [label="Exit block"];
}
142 [label="Exit when branch result"];
130 [label="Enter when branch result"];
subgraph cluster_33 {
color=blue
131 [label="Enter block"];
132 [label="Jump: ^test_5 Unit"];
133 [label="Stub" style="filled" fillcolor=gray];
134 [label="Exit block" style="filled" fillcolor=gray];
}
135 [label="Exit when branch result" style="filled" fillcolor=gray];
122 [label="Exit when"];
}
143 [label="Variable declaration: lval a: R|kotlin/Any|"];
144 [label="Access variable R|<local>/a|"];
145 [label="Function call: R|<local>/a|.R|/baz|()"];
146 [label="Access variable R|<local>/d|"];
147 [label="Access variable R|/D.any|"];
148 [label="Function call: R|<local>/d|.R|/D.any|.R|/baz|()"];
149 [label="Access variable R|<local>/a|"];
150 [label="Type operator: (R|<local>/a| as R|A|)"];
151 [label="Access variable R|<local>/a|"];
152 [label="Function call: R|<local>/a|.R|/A.foo|()"];
120 [label="Exit function test_5" style="filled" fillcolor=red];
118 [label="Enter function getter" style="filled" fillcolor=red];
119 [label="Exit function getter" style="filled" fillcolor=red];
}
119 -> {121};
121 -> {123};
122 -> {143};
123 -> {124};
124 -> {125};
125 -> {126};
126 -> {127};
118 -> {119};
subgraph cluster_29 {
color=red
124 [label="Enter class D" style="filled" fillcolor=red];
subgraph cluster_30 {
color=blue
120 [label="Enter property" style="filled" fillcolor=red];
122 [label="Access variable R|<local>/any|"];
121 [label="Exit property" style="filled" fillcolor=red];
}
123 [label="Exit class D" style="filled" fillcolor=red];
}
124 -> {120} [color=green];
120 -> {122};
121 -> {123} [color=green];
122 -> {121};
subgraph cluster_31 {
color=red
125 [label="Enter function baz" style="filled" fillcolor=red];
subgraph cluster_32 {
color=blue
127 [label="Enter block"];
128 [label="Exit block"];
}
126 [label="Exit function baz" style="filled" fillcolor=red];
}
125 -> {127};
127 -> {128};
128 -> {129};
129 -> {130 136};
130 -> {131};
128 -> {126};
subgraph cluster_33 {
color=red
129 [label="Enter function test_5" style="filled" fillcolor=red];
subgraph cluster_34 {
color=blue
131 [label="Enter block"];
subgraph cluster_35 {
color=blue
132 [label="Enter when"];
134 [label="Access variable R|<local>/d|"];
135 [label="Access variable R|/D.any|"];
136 [label="Variable declaration: lval <elvis>: R|kotlin/Any?|"];
subgraph cluster_36 {
color=blue
137 [label="Enter when branch condition "];
138 [label="Const: Null(null)"];
139 [label="Operator =="];
140 [label="Exit when branch condition"];
}
subgraph cluster_37 {
color=blue
147 [label="Enter when branch condition else"];
148 [label="Exit when branch condition"];
}
149 [label="Enter when branch result"];
subgraph cluster_38 {
color=blue
150 [label="Enter block"];
151 [label="Access variable R|<local>/<elvis>|"];
152 [label="Exit block"];
}
153 [label="Exit when branch result"];
141 [label="Enter when branch result"];
subgraph cluster_39 {
color=blue
142 [label="Enter block"];
143 [label="Jump: ^test_5 Unit"];
144 [label="Stub" style="filled" fillcolor=gray];
145 [label="Exit block" style="filled" fillcolor=gray];
}
146 [label="Exit when branch result" style="filled" fillcolor=gray];
133 [label="Exit when"];
}
154 [label="Variable declaration: lval a: R|kotlin/Any|"];
155 [label="Access variable R|<local>/a|"];
156 [label="Function call: R|<local>/a|.R|/baz|()"];
157 [label="Access variable R|<local>/d|"];
158 [label="Access variable R|/D.any|"];
159 [label="Function call: R|<local>/d|.R|/D.any|.R|/baz|()"];
160 [label="Access variable R|<local>/a|"];
161 [label="Type operator: (R|<local>/a| as R|A|)"];
162 [label="Access variable R|<local>/a|"];
163 [label="Function call: R|<local>/a|.R|/A.foo|()"];
164 [label="Exit block"];
}
130 [label="Exit function test_5" style="filled" fillcolor=red];
}
129 -> {131};
131 -> {132};
132 -> {120};
132 -> {133} [style=dotted];
133 -> {134} [style=dotted];
134 -> {135} [style=dotted];
135 -> {122} [style=dotted];
132 -> {134};
133 -> {154};
134 -> {135};
135 -> {136};
136 -> {137};
137 -> {138};
138 -> {139};
139 -> {140};
140 -> {141};
140 -> {141 147};
141 -> {142};
142 -> {122};
143 -> {144};
144 -> {145};
145 -> {146};
146 -> {147};
142 -> {143};
143 -> {130};
143 -> {144} [style=dotted];
144 -> {145} [style=dotted];
145 -> {146} [style=dotted];
146 -> {133} [style=dotted];
147 -> {148};
148 -> {149};
149 -> {150};
150 -> {151};
151 -> {152};
152 -> {120};
subgraph cluster_34 {
color=red
153 [label="Enter function test_6" style="filled" fillcolor=red];
155 [label="Access variable R|<local>/d1|"];
156 [label="Access variable R|/D.any|"];
157 [label="Variable declaration: lval a: R|kotlin/Any?|"];
158 [label="Access variable R|<local>/a|"];
159 [label="Type operator: (R|<local>/a| as R|A|)"];
160 [label="Access variable R|<local>/a|"];
161 [label="Function call: R|<local>/a|.R|/A.foo|()"];
162 [label="Access variable R|<local>/d1|"];
163 [label="Access variable R|/D.any|"];
164 [label="Function call: R|<local>/d1|.R|/D.any|.R|/A.foo|()"];
165 [label="Access variable R|<local>/d1|"];
166 [label="Access variable R|/D.any|"];
167 [label="Function call: R|<local>/d1|.R|/D.any|.R|/baz|()"];
154 [label="Exit function test_6" style="filled" fillcolor=red];
}
153 -> {155};
152 -> {153};
153 -> {133};
154 -> {155};
155 -> {156};
156 -> {157};
157 -> {158};
@@ -439,52 +452,96 @@ digraph boundSmartcasts_kt {
161 -> {162};
162 -> {163};
163 -> {164};
164 -> {165};
165 -> {166};
166 -> {167};
167 -> {154};
164 -> {130};
subgraph cluster_35 {
subgraph cluster_40 {
color=red
168 [label="Enter function test_7" style="filled" fillcolor=red];
170 [label="Access variable R|<local>/d1|"];
171 [label="Enter safe call"];
173 [label="Access variable R|/D.any|"];
172 [label="Exit safe call"];
174 [label="Variable declaration: lval a: R|kotlin/Any?|"];
175 [label="Access variable R|<local>/d2|"];
176 [label="Enter safe call"];
178 [label="Access variable R|/D.any|"];
177 [label="Exit safe call"];
179 [label="Variable declaration: lval b: R|kotlin/Any?|"];
180 [label="Access variable R|<local>/a|"];
181 [label="Type operator: (R|<local>/a| as R|A|)"];
182 [label="Access variable R|<local>/a|"];
183 [label="Function call: R|<local>/a|.R|/A.foo|()"];
184 [label="Access variable R|<local>/b|"];
185 [label="Type operator: (R|<local>/b| as R|B|)"];
186 [label="Access variable R|<local>/b|"];
187 [label="Function call: R|<local>/b|.R|/B.bar|()"];
169 [label="Exit function test_7" style="filled" fillcolor=red];
165 [label="Enter function test_6" style="filled" fillcolor=red];
subgraph cluster_41 {
color=blue
167 [label="Enter block"];
168 [label="Access variable R|<local>/d1|"];
169 [label="Access variable R|/D.any|"];
170 [label="Variable declaration: lval a: R|kotlin/Any?|"];
171 [label="Access variable R|<local>/a|"];
172 [label="Type operator: (R|<local>/a| as R|A|)"];
173 [label="Access variable R|<local>/a|"];
174 [label="Function call: R|<local>/a|.R|/A.foo|()"];
175 [label="Access variable R|<local>/d1|"];
176 [label="Access variable R|/D.any|"];
177 [label="Function call: R|<local>/d1|.R|/D.any|.R|/A.foo|()"];
178 [label="Access variable R|<local>/d1|"];
179 [label="Access variable R|/D.any|"];
180 [label="Function call: R|<local>/d1|.R|/D.any|.R|/baz|()"];
181 [label="Exit block"];
}
166 [label="Exit function test_6" style="filled" fillcolor=red];
}
168 -> {170};
170 -> {171 172};
171 -> {173};
172 -> {174};
173 -> {172};
165 -> {167};
167 -> {168};
168 -> {169};
169 -> {170};
170 -> {171};
171 -> {172};
172 -> {173};
173 -> {174};
174 -> {175};
175 -> {176 177};
176 -> {178};
177 -> {179};
178 -> {177};
175 -> {176};
176 -> {177};
177 -> {178};
178 -> {179};
179 -> {180};
180 -> {181};
181 -> {182};
182 -> {183};
183 -> {184};
181 -> {166};
subgraph cluster_42 {
color=red
182 [label="Enter function test_7" style="filled" fillcolor=red];
subgraph cluster_43 {
color=blue
184 [label="Enter block"];
185 [label="Access variable R|<local>/d1|"];
186 [label="Enter safe call"];
188 [label="Access variable R|/D.any|"];
187 [label="Exit safe call"];
189 [label="Variable declaration: lval a: R|kotlin/Any?|"];
190 [label="Access variable R|<local>/d2|"];
191 [label="Enter safe call"];
193 [label="Access variable R|/D.any|"];
192 [label="Exit safe call"];
194 [label="Variable declaration: lval b: R|kotlin/Any?|"];
195 [label="Access variable R|<local>/a|"];
196 [label="Type operator: (R|<local>/a| as R|A|)"];
197 [label="Access variable R|<local>/a|"];
198 [label="Function call: R|<local>/a|.R|/A.foo|()"];
199 [label="Access variable R|<local>/b|"];
200 [label="Type operator: (R|<local>/b| as R|B|)"];
201 [label="Access variable R|<local>/b|"];
202 [label="Function call: R|<local>/b|.R|/B.bar|()"];
203 [label="Exit block"];
}
183 [label="Exit function test_7" style="filled" fillcolor=red];
}
182 -> {184};
184 -> {185};
185 -> {186};
186 -> {187};
187 -> {169};
185 -> {186 187};
186 -> {188};
187 -> {189};
188 -> {187};
189 -> {190};
190 -> {191 192};
191 -> {193};
192 -> {194};
193 -> {192};
194 -> {195};
195 -> {196};
196 -> {197};
197 -> {198};
198 -> {199};
199 -> {200};
200 -> {201};
201 -> {202};
202 -> {203};
203 -> {183};
}
@@ -14,10 +14,10 @@ digraph functionCallBound_kt {
subgraph cluster_1 {
color=red
3 [label="Enter class Base" style="filled" fillcolor=red];
4 [label="Exit class Base" style="filled" fillcolor=red];
4 [label="Enter class Base" style="filled" fillcolor=red];
3 [label="Exit class Base" style="filled" fillcolor=red];
}
3 -> {4} [color=green];
4 -> {3} [color=green];
subgraph cluster_2 {
color=red
@@ -30,83 +30,94 @@ digraph functionCallBound_kt {
subgraph cluster_3 {
color=red
13 [label="Enter class Sub" style="filled" fillcolor=red];
subgraph cluster_4 {
color=blue
8 [label="Enter function getter" style="filled" fillcolor=red];
9 [label="Exit function getter" style="filled" fillcolor=red];
}
8 [label="Enter function getter" style="filled" fillcolor=red];
9 [label="Exit function getter" style="filled" fillcolor=red];
}
8 -> {9};
subgraph cluster_4 {
color=red
14 [label="Enter class Sub" style="filled" fillcolor=red];
subgraph cluster_5 {
color=blue
10 [label="Enter property" style="filled" fillcolor=red];
12 [label="Access variable R|<local>/data|"];
11 [label="Exit property" style="filled" fillcolor=red];
}
14 [label="Exit class Sub" style="filled" fillcolor=red];
13 [label="Exit class Sub" style="filled" fillcolor=red];
}
13 -> {10} [color=green];
14 -> {10} [color=green];
10 -> {12};
11 -> {14} [color=green];
11 -> {13} [color=green];
12 -> {11};
8 -> {9};
subgraph cluster_6 {
color=red
15 [label="Enter function isOk" style="filled" fillcolor=red];
17 [label="Const: Boolean(true)"];
18 [label="Jump: ^isOk Boolean(true)"];
19 [label="Stub" style="filled" fillcolor=gray];
subgraph cluster_7 {
color=blue
17 [label="Enter block"];
18 [label="Const: Boolean(true)"];
19 [label="Jump: ^isOk Boolean(true)"];
20 [label="Stub" style="filled" fillcolor=gray];
21 [label="Exit block" style="filled" fillcolor=gray];
}
16 [label="Exit function isOk" style="filled" fillcolor=red];
}
15 -> {17};
17 -> {18};
18 -> {16};
18 -> {19} [style=dotted];
19 -> {16} [style=dotted];
18 -> {19};
19 -> {16};
19 -> {20} [style=dotted];
20 -> {21} [style=dotted];
21 -> {16} [style=dotted];
subgraph cluster_7 {
subgraph cluster_8 {
color=red
20 [label="Enter function check" style="filled" fillcolor=red];
subgraph cluster_8 {
22 [label="Enter function check" style="filled" fillcolor=red];
subgraph cluster_9 {
color=blue
22 [label="Enter when"];
subgraph cluster_9 {
color=blue
24 [label="Enter when branch condition "];
25 [label="Access variable R|<local>/base|"];
26 [label="Type operator: (R|<local>/base| as? R|Sub|)"];
27 [label="Enter safe call"];
29 [label="Function call: $subj$.R|/isOk|()"];
28 [label="Exit safe call"];
30 [label="Const: Boolean(true)"];
31 [label="Operator =="];
32 [label="Exit when branch condition"];
}
24 [label="Enter block"];
subgraph cluster_10 {
color=blue
39 [label="Enter when branch condition else"];
40 [label="Exit when branch condition"];
25 [label="Enter when"];
subgraph cluster_11 {
color=blue
27 [label="Enter when branch condition "];
28 [label="Access variable R|<local>/base|"];
29 [label="Type operator: (R|<local>/base| as? R|Sub|)"];
30 [label="Enter safe call"];
32 [label="Function call: $subj$.R|/isOk|()"];
31 [label="Exit safe call"];
33 [label="Const: Boolean(true)"];
34 [label="Operator =="];
35 [label="Exit when branch condition"];
}
subgraph cluster_12 {
color=blue
42 [label="Enter when branch condition else"];
43 [label="Exit when branch condition"];
}
44 [label="Enter when branch result"];
subgraph cluster_13 {
color=blue
45 [label="Enter block"];
46 [label="Access variable R|<local>/base|"];
47 [label="Exit block"];
}
48 [label="Exit when branch result"];
36 [label="Enter when branch result"];
subgraph cluster_14 {
color=blue
37 [label="Enter block"];
38 [label="Access variable R|<local>/base|"];
39 [label="Access variable R|/Sub.data|"];
40 [label="Exit block"];
}
41 [label="Exit when branch result"];
26 [label="Exit when"];
}
41 [label="Enter when branch result"];
subgraph cluster_11 {
color=blue
42 [label="Enter block"];
43 [label="Access variable R|<local>/base|"];
44 [label="Exit block"];
}
45 [label="Exit when branch result"];
33 [label="Enter when branch result"];
subgraph cluster_12 {
color=blue
34 [label="Enter block"];
35 [label="Access variable R|<local>/base|"];
36 [label="Access variable R|/Sub.data|"];
37 [label="Exit block"];
}
38 [label="Exit when branch result"];
23 [label="Exit when"];
}
46 [label="Jump: ^check when () {
49 [label="Jump: ^check when () {
==((R|<local>/base| as? R|Sub|)?.{ $subj$.R|/isOk|() }, Boolean(true)) -> {
R|<local>/base|.R|/Sub.data|
}
@@ -115,36 +126,40 @@ digraph functionCallBound_kt {
}
}
"];
47 [label="Stub" style="filled" fillcolor=gray];
21 [label="Exit function check" style="filled" fillcolor=red];
50 [label="Stub" style="filled" fillcolor=gray];
51 [label="Exit block" style="filled" fillcolor=gray];
}
23 [label="Exit function check" style="filled" fillcolor=red];
}
20 -> {22};
22 -> {24};
23 -> {46};
24 -> {25};
25 -> {26};
26 -> {27 28};
27 -> {29};
28 -> {30};
29 -> {28};
30 -> {31};
31 -> {32};
32 -> {33 39};
25 -> {27};
26 -> {49};
27 -> {28};
28 -> {29};
29 -> {30 31};
30 -> {32};
31 -> {33};
32 -> {31};
33 -> {34};
34 -> {35};
35 -> {36};
35 -> {36 42};
36 -> {37};
37 -> {38};
38 -> {23};
38 -> {39};
39 -> {40};
40 -> {41};
41 -> {42};
41 -> {26};
42 -> {43};
43 -> {44};
44 -> {45};
45 -> {23};
46 -> {21};
46 -> {47} [style=dotted];
47 -> {21} [style=dotted];
45 -> {46};
46 -> {47};
47 -> {48};
48 -> {26};
49 -> {23};
49 -> {50} [style=dotted];
50 -> {51} [style=dotted];
51 -> {23} [style=dotted];
}