File tree Expand file tree Collapse file tree 3 files changed +12
-33
lines changed
cpp/ql/src/semmle/code/cpp/ir/implementation
csharp/ql/src/experimental/ir/implementation/unaliased_ssa/internal Expand file tree Collapse file tree 3 files changed +12
-33
lines changed Original file line number Diff line number Diff line change @@ -65,17 +65,10 @@ private module Cached {
65
65
instr = reusedPhiInstruction ( _) and
66
66
// Check that the phi instruction is *not* degenerate, but we can't use
67
67
// getDegeneratePhiOperand in the first stage with phi instyructions
68
- exists (
69
- OldIR:: PhiInputOperand operand1 , OldIR:: PhiInputOperand operand2 ,
70
- OldInstruction oldInstruction
71
- |
72
- oldInstruction = instr and
73
- operand1 = oldInstruction .( OldIR:: PhiInstruction ) .getAnInputOperand ( ) and
74
- operand1 .getPredecessorBlock ( ) instanceof OldBlock and
75
- operand2 = oldInstruction .( OldIR:: PhiInstruction ) .getAnInputOperand ( ) and
76
- operand2 .getPredecessorBlock ( ) instanceof OldBlock and
77
- operand1 != operand2
78
- )
68
+ not exists ( unique( OldIR:: PhiInputOperand operand |
69
+ operand = instr .( OldIR:: PhiInstruction ) .getAnInputOperand ( ) and
70
+ operand .getPredecessorBlock ( ) instanceof OldBlock
71
+ ) )
79
72
or
80
73
instr instanceof TChiInstruction
81
74
or
Original file line number Diff line number Diff line change @@ -65,17 +65,10 @@ private module Cached {
65
65
instr = reusedPhiInstruction ( _) and
66
66
// Check that the phi instruction is *not* degenerate, but we can't use
67
67
// getDegeneratePhiOperand in the first stage with phi instyructions
68
- exists (
69
- OldIR:: PhiInputOperand operand1 , OldIR:: PhiInputOperand operand2 ,
70
- OldInstruction oldInstruction
71
- |
72
- oldInstruction = instr and
73
- operand1 = oldInstruction .( OldIR:: PhiInstruction ) .getAnInputOperand ( ) and
74
- operand1 .getPredecessorBlock ( ) instanceof OldBlock and
75
- operand2 = oldInstruction .( OldIR:: PhiInstruction ) .getAnInputOperand ( ) and
76
- operand2 .getPredecessorBlock ( ) instanceof OldBlock and
77
- operand1 != operand2
78
- )
68
+ not exists ( unique( OldIR:: PhiInputOperand operand |
69
+ operand = instr .( OldIR:: PhiInstruction ) .getAnInputOperand ( ) and
70
+ operand .getPredecessorBlock ( ) instanceof OldBlock
71
+ ) )
79
72
or
80
73
instr instanceof TChiInstruction
81
74
or
Original file line number Diff line number Diff line change @@ -65,17 +65,10 @@ private module Cached {
65
65
instr = reusedPhiInstruction ( _) and
66
66
// Check that the phi instruction is *not* degenerate, but we can't use
67
67
// getDegeneratePhiOperand in the first stage with phi instyructions
68
- exists (
69
- OldIR:: PhiInputOperand operand1 , OldIR:: PhiInputOperand operand2 ,
70
- OldInstruction oldInstruction
71
- |
72
- oldInstruction = instr and
73
- operand1 = oldInstruction .( OldIR:: PhiInstruction ) .getAnInputOperand ( ) and
74
- operand1 .getPredecessorBlock ( ) instanceof OldBlock and
75
- operand2 = oldInstruction .( OldIR:: PhiInstruction ) .getAnInputOperand ( ) and
76
- operand2 .getPredecessorBlock ( ) instanceof OldBlock and
77
- operand1 != operand2
78
- )
68
+ not exists ( unique( OldIR:: PhiInputOperand operand |
69
+ operand = instr .( OldIR:: PhiInstruction ) .getAnInputOperand ( ) and
70
+ operand .getPredecessorBlock ( ) instanceof OldBlock
71
+ ) )
79
72
or
80
73
instr instanceof TChiInstruction
81
74
or
You can’t perform that action at this time.
0 commit comments