@@ -35,38 +35,21 @@ class SsaUseNode extends DataFlow::Node, TSsaUseNode {
35
35
override Location getLocation ( ) { result = expr .getLocation ( ) }
36
36
}
37
37
38
- class SsaPhiReadNode extends DataFlow:: Node , TSsaPhiReadNode {
39
- private Ssa2:: PhiReadNode phi ;
38
+ class SsaSynthReadNode extends DataFlow:: Node , TSsaSynthReadNode {
39
+ private Ssa2:: SsaSynthReadNode read ;
40
40
41
- SsaPhiReadNode ( ) { this = TSsaPhiReadNode ( phi ) }
41
+ SsaSynthReadNode ( ) { this = TSsaSynthReadNode ( read ) }
42
42
43
43
cached
44
- override string toString ( ) { result = "[ssa-phi-read] " + phi .getSourceVariable ( ) .getName ( ) }
45
-
46
- cached
47
- override StmtContainer getContainer ( ) { result = phi .getSourceVariable ( ) .getDeclaringContainer ( ) }
48
-
49
- cached
50
- override Location getLocation ( ) { result = phi .getLocation ( ) }
51
- }
52
-
53
- class SsaInputNode extends DataFlow:: Node , TSsaInputNode {
54
- private Ssa2:: SsaInputNode input ;
55
-
56
- SsaInputNode ( ) { this = TSsaInputNode ( input ) }
57
-
58
- cached
59
- override string toString ( ) {
60
- result = "[ssa-input] " + input .getDefinitionExt ( ) .getSourceVariable ( ) .getName ( )
61
- }
44
+ override string toString ( ) { result = "[ssa-synth-read] " + read .getSourceVariable ( ) .getName ( ) }
62
45
63
46
cached
64
47
override StmtContainer getContainer ( ) {
65
- result = input . getDefinitionExt ( ) .getSourceVariable ( ) .getDeclaringContainer ( )
48
+ result = read .getSourceVariable ( ) .getDeclaringContainer ( )
66
49
}
67
50
68
51
cached
69
- override Location getLocation ( ) { result = input .getLocation ( ) }
52
+ override Location getLocation ( ) { result = read .getLocation ( ) }
70
53
}
71
54
72
55
class FlowSummaryNode extends DataFlow:: Node , TFlowSummaryNode {
@@ -675,9 +658,7 @@ predicate nodeIsHidden(Node node) {
675
658
or
676
659
node instanceof SsaUseNode
677
660
or
678
- node instanceof SsaPhiReadNode
679
- or
680
- node instanceof SsaInputNode
661
+ node instanceof SsaSynthReadNode
681
662
}
682
663
683
664
predicate neverSkipInPathGraph ( Node node ) {
@@ -1258,12 +1239,10 @@ Node getNodeFromSsa2(Ssa2::Node node) {
1258
1239
result = TImplicitThisUse ( use , true )
1259
1240
)
1260
1241
or
1261
- result = TSsaPhiReadNode ( node .( Ssa2:: SsaDefinitionExtNode ) .getDefinitionExt ( ) )
1262
- or
1263
- result = TSsaInputNode ( node .( Ssa2:: SsaInputNode ) )
1242
+ result = TSsaSynthReadNode ( node )
1264
1243
or
1265
1244
exists ( SsaPhiNode legacyPhi , Ssa2:: PhiNode ssaPhi |
1266
- node .( Ssa2:: SsaDefinitionExtNode ) . getDefinitionExt ( ) = ssaPhi and
1245
+ node .( Ssa2:: SsaDefinitionNode ) . getDefinition ( ) = ssaPhi and
1267
1246
samePhi ( legacyPhi , ssaPhi ) and
1268
1247
result = TSsaDefNode ( legacyPhi )
1269
1248
)
0 commit comments