[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
+29 -15
View File
@@ -6,29 +6,43 @@ digraph simple_kt {
subgraph cluster_0 {
color=red
0 [label="Enter function foo" style="filled" fillcolor=red];
subgraph cluster_1 {
color=blue
2 [label="Enter block"];
3 [label="Exit block"];
}
1 [label="Exit function foo" style="filled" fillcolor=red];
}
0 -> {1};
0 -> {2};
2 -> {3};
3 -> {1};
subgraph cluster_1 {
subgraph cluster_2 {
color=red
2 [label="Enter function test" style="filled" fillcolor=red];
4 [label="Const: Int(1)"];
5 [label="Variable declaration: lval x: R|kotlin/Int|"];
6 [label="Access variable R|<local>/x|"];
7 [label="Const: Int(1)"];
8 [label="Function call: R|<local>/x|.R|kotlin/Int.plus|(...)"];
9 [label="Variable declaration: lval y: R|kotlin/Int|"];
10 [label="Function call: R|/foo|()"];
3 [label="Exit function test" style="filled" fillcolor=red];
4 [label="Enter function test" style="filled" fillcolor=red];
subgraph cluster_3 {
color=blue
6 [label="Enter block"];
7 [label="Const: Int(1)"];
8 [label="Variable declaration: lval x: R|kotlin/Int|"];
9 [label="Access variable R|<local>/x|"];
10 [label="Const: Int(1)"];
11 [label="Function call: R|<local>/x|.R|kotlin/Int.plus|(...)"];
12 [label="Variable declaration: lval y: R|kotlin/Int|"];
13 [label="Function call: R|/foo|()"];
14 [label="Exit block"];
}
5 [label="Exit function test" style="filled" fillcolor=red];
}
2 -> {4};
4 -> {5};
5 -> {6};
4 -> {6};
6 -> {7};
7 -> {8};
8 -> {9};
9 -> {10};
10 -> {3};
10 -> {11};
11 -> {12};
12 -> {13};
13 -> {14};
14 -> {5};
}