Skip to content

Commit fce7a5f

Browse files
C++: Final IR reshuffle
Moved IR flavors into "implementation", with internal files under "implementation/internal". Made `IRBlockConstruction` just a nested module of `IRConstruction`/`SSAConstruction`, so it gets picked up from the `Construction` parameter of the `IR` module, rather than being picked up just from being in the same directory as `IRBlock`.
1 parent aa4436f commit fce7a5f

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

71 files changed

+83
-81
lines changed

config/identical-files.json

Lines changed: 32 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -1,58 +1,58 @@
11
{
22
"C++ IR Instruction": [
3-
"cpp/ql/src/semmle/code/cpp/ir/internal/raw_ir/Instruction.qll",
4-
"cpp/ql/src/semmle/code/cpp/ir/internal/ssa_ir/Instruction.qll",
5-
"cpp/ql/src/semmle/code/cpp/ir/internal/aliased_ssa_ir/Instruction.qll"
3+
"cpp/ql/src/semmle/code/cpp/ir/implementation/raw/Instruction.qll",
4+
"cpp/ql/src/semmle/code/cpp/ir/implementation/unaliased_ssa/Instruction.qll",
5+
"cpp/ql/src/semmle/code/cpp/ir/implementation/aliased_ssa/Instruction.qll"
66
],
77
"C++ IR IRBlock": [
8-
"cpp/ql/src/semmle/code/cpp/ir/internal/raw_ir/IRBlock.qll",
9-
"cpp/ql/src/semmle/code/cpp/ir/internal/ssa_ir/IRBlock.qll",
10-
"cpp/ql/src/semmle/code/cpp/ir/internal/aliased_ssa_ir/IRBlock.qll"
8+
"cpp/ql/src/semmle/code/cpp/ir/implementation/raw/IRBlock.qll",
9+
"cpp/ql/src/semmle/code/cpp/ir/implementation/unaliased_ssa/IRBlock.qll",
10+
"cpp/ql/src/semmle/code/cpp/ir/implementation/aliased_ssa/IRBlock.qll"
1111
],
1212
"C++ IR IRVariable": [
13-
"cpp/ql/src/semmle/code/cpp/ir/internal/raw_ir/IRVariable.qll",
14-
"cpp/ql/src/semmle/code/cpp/ir/internal/ssa_ir/IRVariable.qll",
15-
"cpp/ql/src/semmle/code/cpp/ir/internal/aliased_ssa_ir/IRVariable.qll"
13+
"cpp/ql/src/semmle/code/cpp/ir/implementation/raw/IRVariable.qll",
14+
"cpp/ql/src/semmle/code/cpp/ir/implementation/unaliased_ssa/IRVariable.qll",
15+
"cpp/ql/src/semmle/code/cpp/ir/implementation/aliased_ssa/IRVariable.qll"
1616
],
1717
"C++ IR FunctionIR": [
18-
"cpp/ql/src/semmle/code/cpp/ir/internal/raw_ir/FunctionIR.qll",
19-
"cpp/ql/src/semmle/code/cpp/ir/internal/ssa_ir/FunctionIR.qll",
20-
"cpp/ql/src/semmle/code/cpp/ir/internal/aliased_ssa_ir/FunctionIR.qll"
18+
"cpp/ql/src/semmle/code/cpp/ir/implementation/raw/FunctionIR.qll",
19+
"cpp/ql/src/semmle/code/cpp/ir/implementation/unaliased_ssa/FunctionIR.qll",
20+
"cpp/ql/src/semmle/code/cpp/ir/implementation/aliased_ssa/FunctionIR.qll"
2121
],
2222
"C++ IR OperandTag": [
23-
"cpp/ql/src/semmle/code/cpp/ir/internal/raw_ir/OperandTag.qll",
24-
"cpp/ql/src/semmle/code/cpp/ir/internal/ssa_ir/OperandTag.qll",
25-
"cpp/ql/src/semmle/code/cpp/ir/internal/aliased_ssa_ir/OperandTag.qll"
23+
"cpp/ql/src/semmle/code/cpp/ir/implementation/raw/OperandTag.qll",
24+
"cpp/ql/src/semmle/code/cpp/ir/implementation/unaliased_ssa/OperandTag.qll",
25+
"cpp/ql/src/semmle/code/cpp/ir/implementation/aliased_ssa/OperandTag.qll"
2626
],
2727
"C++ IR IRImpl": [
28-
"cpp/ql/src/semmle/code/cpp/ir/internal/raw_ir/IR.qll",
29-
"cpp/ql/src/semmle/code/cpp/ir/internal/ssa_ir/IR.qll",
30-
"cpp/ql/src/semmle/code/cpp/ir/internal/aliased_ssa_ir/IR.qll"
28+
"cpp/ql/src/semmle/code/cpp/ir/implementation/raw/IR.qll",
29+
"cpp/ql/src/semmle/code/cpp/ir/implementation/unaliased_ssa/IR.qll",
30+
"cpp/ql/src/semmle/code/cpp/ir/implementation/aliased_ssa/IR.qll"
3131
],
3232
"C++ IR IRSanityImpl": [
33-
"cpp/ql/src/semmle/code/cpp/ir/internal/raw_ir/IRSanity.qll",
34-
"cpp/ql/src/semmle/code/cpp/ir/internal/ssa_ir/IRSanity.qll",
35-
"cpp/ql/src/semmle/code/cpp/ir/internal/aliased_ssa_ir/IRSanity.qll"
33+
"cpp/ql/src/semmle/code/cpp/ir/implementation/raw/IRSanity.qll",
34+
"cpp/ql/src/semmle/code/cpp/ir/implementation/unaliased_ssa/IRSanity.qll",
35+
"cpp/ql/src/semmle/code/cpp/ir/implementation/aliased_ssa/IRSanity.qll"
3636
],
3737
"C++ IR PrintIRImpl": [
38-
"cpp/ql/src/semmle/code/cpp/ir/internal/raw_ir/PrintIR.qll",
39-
"cpp/ql/src/semmle/code/cpp/ir/internal/ssa_ir/PrintIR.qll",
40-
"cpp/ql/src/semmle/code/cpp/ir/internal/aliased_ssa_ir/PrintIR.qll"
38+
"cpp/ql/src/semmle/code/cpp/ir/implementation/raw/PrintIR.qll",
39+
"cpp/ql/src/semmle/code/cpp/ir/implementation/unaliased_ssa/PrintIR.qll",
40+
"cpp/ql/src/semmle/code/cpp/ir/implementation/aliased_ssa/PrintIR.qll"
4141
],
4242
"C++ SSA AliasAnalysis": [
43-
"cpp/ql/src/semmle/code/cpp/ir/internal/ssa_ir/AliasAnalysis.qll",
44-
"cpp/ql/src/semmle/code/cpp/ir/internal/aliased_ssa_ir/AliasAnalysis.qll"
43+
"cpp/ql/src/semmle/code/cpp/ir/implementation/unaliased_ssa/internal/AliasAnalysis.qll",
44+
"cpp/ql/src/semmle/code/cpp/ir/implementation/aliased_ssa/internal/AliasAnalysis.qll"
4545
],
4646
"C++ SSA SimpleSSA": [
47-
"cpp/ql/src/semmle/code/cpp/ir/internal/ssa_ir/SimpleSSA.qll",
48-
"cpp/ql/src/semmle/code/cpp/ir/internal/aliased_ssa_ir/SimpleSSA.qll"
47+
"cpp/ql/src/semmle/code/cpp/ir/implementation/unaliased_ssa/internal/SimpleSSA.qll",
48+
"cpp/ql/src/semmle/code/cpp/ir/implementation/aliased_ssa/internal/SimpleSSA.qll"
4949
],
5050
"C++ SSA IRBlockConstruction": [
51-
"cpp/ql/src/semmle/code/cpp/ir/internal/ssa_ir/IRBlockConstruction.qll",
52-
"cpp/ql/src/semmle/code/cpp/ir/internal/aliased_ssa_ir/IRBlockConstruction.qll"
51+
"cpp/ql/src/semmle/code/cpp/ir/implementation/unaliased_ssa/internal/IRBlockConstruction.qll",
52+
"cpp/ql/src/semmle/code/cpp/ir/implementation/aliased_ssa/internal/IRBlockConstruction.qll"
5353
],
5454
"C++ SSA SSAConstruction": [
55-
"cpp/ql/src/semmle/code/cpp/ir/internal/ssa_ir/SSAConstruction.qll",
56-
"cpp/ql/src/semmle/code/cpp/ir/internal/aliased_ssa_ir/SSAConstruction.qll"
55+
"cpp/ql/src/semmle/code/cpp/ir/implementation/unaliased_ssa/internal/SSAConstruction.qll",
56+
"cpp/ql/src/semmle/code/cpp/ir/implementation/aliased_ssa/internal/SSAConstruction.qll"
5757
]
5858
}
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
// Most queries should operate on the aliased SSA IR, so that's what we expose
22
// publically as the "IR".
3-
import internal.aliased_ssa.IR
3+
import implementation.aliased_ssa.IR

cpp/ql/src/semmle/code/cpp/ir/IRSanity.ql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@
55
* @id cpp/ir-sanity-check
66
*/
77

8-
import internal.aliased_ssa.IRSanity
8+
import implementation.aliased_ssa.IRSanity

cpp/ql/src/semmle/code/cpp/ir/PrintIR.ql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@
55
* @kind graph
66
*/
77

8-
import internal.aliased_ssa.PrintIR
8+
import implementation.aliased_ssa.PrintIR

cpp/ql/src/semmle/code/cpp/ir/internal/raw/FunctionIR.qll renamed to cpp/ql/src/semmle/code/cpp/ir/implementation/aliased_ssa/FunctionIR.qll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
private import IRInternal
1+
private import internal.IRInternal
22
import Instruction
33
import cpp
44

cpp/ql/src/semmle/code/cpp/ir/internal/aliased_ssa/IR.qll renamed to cpp/ql/src/semmle/code/cpp/ir/implementation/aliased_ssa/IR.qll

File renamed without changes.

cpp/ql/src/semmle/code/cpp/ir/internal/unaliased_ssa/IRBlock.qll renamed to cpp/ql/src/semmle/code/cpp/ir/implementation/aliased_ssa/IRBlock.qll

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
private import IRInternal
2-
private import IRBlockConstruction
1+
private import internal.IRInternal
32
import Instruction
43
import semmle.code.cpp.ir.implementation.EdgeKind
4+
private import Construction::BlockConstruction
55

66
class IRBlock extends TIRBlock {
77
final string toString() {

cpp/ql/src/semmle/code/cpp/ir/internal/aliased_ssa/IRSanity.ql renamed to cpp/ql/src/semmle/code/cpp/ir/implementation/aliased_ssa/IRSanity.ql

File renamed without changes.

cpp/ql/src/semmle/code/cpp/ir/internal/aliased_ssa/IRSanity.qll renamed to cpp/ql/src/semmle/code/cpp/ir/implementation/aliased_ssa/IRSanity.qll

File renamed without changes.

cpp/ql/src/semmle/code/cpp/ir/internal/aliased_ssa/IRVariable.qll renamed to cpp/ql/src/semmle/code/cpp/ir/implementation/aliased_ssa/IRVariable.qll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
private import IRInternal
1+
private import internal.IRInternal
22
import FunctionIR
33
import cpp
44
import semmle.code.cpp.ir.implementation.TempVariableTag

0 commit comments

Comments
 (0)