File tree Expand file tree Collapse file tree
cpp/ql/src/semmle/code/cpp/ir/implementation
aliased_ssa/internal/reachability
raw/internal/reachability
unaliased_ssa/internal/reachability Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -22,7 +22,9 @@ IRBlock getAFeasiblePredecessor(IRBlock successor) {
2222}
2323
2424predicate isBlockReachable ( IRBlock block ) {
25- getAFeasiblePredecessor * ( block ) = block .getFunctionIR ( ) .getEntryBlock ( )
25+ exists ( FunctionIR f |
26+ getAFeasiblePredecessor * ( block ) = f .getEntryBlock ( )
27+ )
2628}
2729
2830predicate isInstructionReachable ( Instruction instr ) {
@@ -43,7 +45,9 @@ class ReachableInstruction extends Instruction {
4345
4446module Graph {
4547 predicate isEntryBlock ( ReachableBlock block ) {
46- block = block .getFunctionIR ( ) .getEntryBlock ( )
48+ exists ( FunctionIR f |
49+ block = f .getEntryBlock ( )
50+ )
4751 }
4852
4953 predicate blockSuccessor ( ReachableBlock pred , ReachableBlock succ ) {
Original file line number Diff line number Diff line change @@ -22,7 +22,9 @@ IRBlock getAFeasiblePredecessor(IRBlock successor) {
2222}
2323
2424predicate isBlockReachable ( IRBlock block ) {
25- getAFeasiblePredecessor * ( block ) = block .getFunctionIR ( ) .getEntryBlock ( )
25+ exists ( FunctionIR f |
26+ getAFeasiblePredecessor * ( block ) = f .getEntryBlock ( )
27+ )
2628}
2729
2830predicate isInstructionReachable ( Instruction instr ) {
@@ -43,7 +45,9 @@ class ReachableInstruction extends Instruction {
4345
4446module Graph {
4547 predicate isEntryBlock ( ReachableBlock block ) {
46- block = block .getFunctionIR ( ) .getEntryBlock ( )
48+ exists ( FunctionIR f |
49+ block = f .getEntryBlock ( )
50+ )
4751 }
4852
4953 predicate blockSuccessor ( ReachableBlock pred , ReachableBlock succ ) {
Original file line number Diff line number Diff line change @@ -22,7 +22,9 @@ IRBlock getAFeasiblePredecessor(IRBlock successor) {
2222}
2323
2424predicate isBlockReachable ( IRBlock block ) {
25- getAFeasiblePredecessor * ( block ) = block .getFunctionIR ( ) .getEntryBlock ( )
25+ exists ( FunctionIR f |
26+ getAFeasiblePredecessor * ( block ) = f .getEntryBlock ( )
27+ )
2628}
2729
2830predicate isInstructionReachable ( Instruction instr ) {
@@ -43,7 +45,9 @@ class ReachableInstruction extends Instruction {
4345
4446module Graph {
4547 predicate isEntryBlock ( ReachableBlock block ) {
46- block = block .getFunctionIR ( ) .getEntryBlock ( )
48+ exists ( FunctionIR f |
49+ block = f .getEntryBlock ( )
50+ )
4751 }
4852
4953 predicate blockSuccessor ( ReachableBlock pred , ReachableBlock succ ) {
You can’t perform that action at this time.
0 commit comments