|
|
|
/* @generated */
|
|
|
|
digraph cfg {
|
|
|
|
"access_ptr#15321479508398739907.c982e7d4bf02ada6326387e65b321af4_1" [label="1: Start access_ptr\nFormals: x:X*\nLocals: c:int f:int \n DECLARE_LOCALS(&return,&c,&f); [line 20, column 1]\n " color=yellow style=filled]
|
|
|
|
|
|
|
|
|
|
|
|
"access_ptr#15321479508398739907.c982e7d4bf02ada6326387e65b321af4_1" -> "access_ptr#15321479508398739907.c982e7d4bf02ada6326387e65b321af4_4" ;
|
|
|
|
"access_ptr#15321479508398739907.c982e7d4bf02ada6326387e65b321af4_2" [label="2: Exit access_ptr \n " color=yellow style=filled]
|
|
|
|
|
|
|
|
|
[clang] enforce that `instruction` always returns one SIL expression
Summary:
Previously, the type of `trans_result` contained a list of SIL expressions.
However, most of the time we expect to get exactly one, and getting a different
number is a soft(!) error, usually returning `-1`.
This splits `trans_result` into `control`, which contains the information
needed for temporary computation (hence when we don't necessarily know the
return value yet), and a new version of `trans_result` that includes `control`,
the previous `exps` list but replaced by a single `return` expression instead,
and a couple other values that made sense to move out of `control`. This allows
some flexibility in the frontend compared to enforcing exactly one return
expression always: if they are not known yet we stick to `control` instead (see
eg `compute_controls_to_parent`).
This creates more garbage temporary identifiers, however they do not show up in
the final cfg. Instead, we see that temporary IDs are now often not
consecutive...
The most painful complication is in the treatment of `DeclRefExpr`, which was
actually returning *two* expressions: the method name and the `this` object.
Now the method name is a separate (optional) field in `trans_result`.
Reviewed By: mbouaziz
Differential Revision: D7881088
fbshipit-source-id: 41ad3b5
7 years ago
|
|
|
"access_ptr#15321479508398739907.c982e7d4bf02ada6326387e65b321af4_3" [label="3: DeclStmt \n n$1=*&x:X* [line 22, column 11]\n _=*n$1:X [line 22, column 11]\n n$3=_fun_X_call(n$1:X*) [line 22, column 11]\n *&c:int=n$3 [line 22, column 3]\n " shape="box"]
|
|
|
|
|
|
|
|
|
|
|
|
"access_ptr#15321479508398739907.c982e7d4bf02ada6326387e65b321af4_3" -> "access_ptr#15321479508398739907.c982e7d4bf02ada6326387e65b321af4_2" ;
|
[clang] enforce that `instruction` always returns one SIL expression
Summary:
Previously, the type of `trans_result` contained a list of SIL expressions.
However, most of the time we expect to get exactly one, and getting a different
number is a soft(!) error, usually returning `-1`.
This splits `trans_result` into `control`, which contains the information
needed for temporary computation (hence when we don't necessarily know the
return value yet), and a new version of `trans_result` that includes `control`,
the previous `exps` list but replaced by a single `return` expression instead,
and a couple other values that made sense to move out of `control`. This allows
some flexibility in the frontend compared to enforcing exactly one return
expression always: if they are not known yet we stick to `control` instead (see
eg `compute_controls_to_parent`).
This creates more garbage temporary identifiers, however they do not show up in
the final cfg. Instead, we see that temporary IDs are now often not
consecutive...
The most painful complication is in the treatment of `DeclRefExpr`, which was
actually returning *two* expressions: the method name and the `this` object.
Now the method name is a separate (optional) field in `trans_result`.
Reviewed By: mbouaziz
Differential Revision: D7881088
fbshipit-source-id: 41ad3b5
7 years ago
|
|
|
"access_ptr#15321479508398739907.c982e7d4bf02ada6326387e65b321af4_4" [label="4: DeclStmt \n n$4=*&x:X* [line 21, column 11]\n n$5=*n$4.f:int [line 21, column 11]\n *&f:int=n$5 [line 21, column 3]\n " shape="box"]
|
|
|
|
|
|
|
|
|
|
|
|
"access_ptr#15321479508398739907.c982e7d4bf02ada6326387e65b321af4_4" -> "access_ptr#15321479508398739907.c982e7d4bf02ada6326387e65b321af4_3" ;
|
|
|
|
"access_ref#4794488565171451856.2c0cb1f039897d6498c9fea4cbfec99e_1" [label="1: Start access_ref\nFormals: x:X&\nLocals: c:int f:int \n DECLARE_LOCALS(&return,&c,&f); [line 15, column 1]\n " color=yellow style=filled]
|
|
|
|
|
|
|
|
|
|
|
|
"access_ref#4794488565171451856.2c0cb1f039897d6498c9fea4cbfec99e_1" -> "access_ref#4794488565171451856.2c0cb1f039897d6498c9fea4cbfec99e_4" ;
|
|
|
|
"access_ref#4794488565171451856.2c0cb1f039897d6498c9fea4cbfec99e_2" [label="2: Exit access_ref \n " color=yellow style=filled]
|
|
|
|
|
|
|
|
|
[clang] enforce that `instruction` always returns one SIL expression
Summary:
Previously, the type of `trans_result` contained a list of SIL expressions.
However, most of the time we expect to get exactly one, and getting a different
number is a soft(!) error, usually returning `-1`.
This splits `trans_result` into `control`, which contains the information
needed for temporary computation (hence when we don't necessarily know the
return value yet), and a new version of `trans_result` that includes `control`,
the previous `exps` list but replaced by a single `return` expression instead,
and a couple other values that made sense to move out of `control`. This allows
some flexibility in the frontend compared to enforcing exactly one return
expression always: if they are not known yet we stick to `control` instead (see
eg `compute_controls_to_parent`).
This creates more garbage temporary identifiers, however they do not show up in
the final cfg. Instead, we see that temporary IDs are now often not
consecutive...
The most painful complication is in the treatment of `DeclRefExpr`, which was
actually returning *two* expressions: the method name and the `this` object.
Now the method name is a separate (optional) field in `trans_result`.
Reviewed By: mbouaziz
Differential Revision: D7881088
fbshipit-source-id: 41ad3b5
7 years ago
|
|
|
"access_ref#4794488565171451856.2c0cb1f039897d6498c9fea4cbfec99e_3" [label="3: DeclStmt \n n$1=*&x:X& [line 17, column 11]\n _=*n$1:X [line 17, column 11]\n n$3=_fun_X_call(n$1:X&) [line 17, column 11]\n *&c:int=n$3 [line 17, column 3]\n " shape="box"]
|
|
|
|
|
|
|
|
|
|
|
|
"access_ref#4794488565171451856.2c0cb1f039897d6498c9fea4cbfec99e_3" -> "access_ref#4794488565171451856.2c0cb1f039897d6498c9fea4cbfec99e_2" ;
|
[clang] enforce that `instruction` always returns one SIL expression
Summary:
Previously, the type of `trans_result` contained a list of SIL expressions.
However, most of the time we expect to get exactly one, and getting a different
number is a soft(!) error, usually returning `-1`.
This splits `trans_result` into `control`, which contains the information
needed for temporary computation (hence when we don't necessarily know the
return value yet), and a new version of `trans_result` that includes `control`,
the previous `exps` list but replaced by a single `return` expression instead,
and a couple other values that made sense to move out of `control`. This allows
some flexibility in the frontend compared to enforcing exactly one return
expression always: if they are not known yet we stick to `control` instead (see
eg `compute_controls_to_parent`).
This creates more garbage temporary identifiers, however they do not show up in
the final cfg. Instead, we see that temporary IDs are now often not
consecutive...
The most painful complication is in the treatment of `DeclRefExpr`, which was
actually returning *two* expressions: the method name and the `this` object.
Now the method name is a separate (optional) field in `trans_result`.
Reviewed By: mbouaziz
Differential Revision: D7881088
fbshipit-source-id: 41ad3b5
7 years ago
|
|
|
"access_ref#4794488565171451856.2c0cb1f039897d6498c9fea4cbfec99e_4" [label="4: DeclStmt \n n$4=*&x:X& [line 16, column 11]\n n$5=*n$4.f:int [line 16, column 11]\n *&f:int=n$5 [line 16, column 3]\n " shape="box"]
|
|
|
|
|
|
|
|
|
|
|
|
"access_ref#4794488565171451856.2c0cb1f039897d6498c9fea4cbfec99e_4" -> "access_ref#4794488565171451856.2c0cb1f039897d6498c9fea4cbfec99e_3" ;
|
|
|
|
"call#X#(5770224879682844394).d055b894c8e89eaff4b8d412706da082_1" [label="1: Start X_call\nFormals: this:X*\nLocals: \n DECLARE_LOCALS(&return); [line 12, column 3]\n " color=yellow style=filled]
|
|
|
|
|
|
|
|
|
|
|
|
"call#X#(5770224879682844394).d055b894c8e89eaff4b8d412706da082_1" -> "call#X#(5770224879682844394).d055b894c8e89eaff4b8d412706da082_3" ;
|
|
|
|
"call#X#(5770224879682844394).d055b894c8e89eaff4b8d412706da082_2" [label="2: Exit X_call \n " color=yellow style=filled]
|
|
|
|
|
|
|
|
|
|
|
|
"call#X#(5770224879682844394).d055b894c8e89eaff4b8d412706da082_3" [label="3: Return Stmt \n n$0=*&this:X* [line 12, column 23]\n n$1=*n$0.f:int [line 12, column 23]\n *&return:int=n$1 [line 12, column 16]\n " shape="box"]
|
|
|
|
|
|
|
|
|
|
|
|
"call#X#(5770224879682844394).d055b894c8e89eaff4b8d412706da082_3" -> "call#X#(5770224879682844394).d055b894c8e89eaff4b8d412706da082_2" ;
|
|
|
|
}
|