Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
d93413f
Cfg: Add ConditionKind and getDual to ConditionalSuccessor.
aschackmull Feb 5, 2026
2f06230
Java: Preparatory tweaks.
aschackmull Feb 6, 2026
0d13877
Java: Replace ControlFlowNode.asCall with Call.getControlFlowNode.
aschackmull Feb 6, 2026
32dbb19
Cfg: Add getEnclosingCallable to shared BasicBlock
aschackmull Feb 6, 2026
9a178ba
Java: Replace idominance tests.
aschackmull Feb 16, 2026
8a02494
Java/Cfg: Introduce new shared CFG library and replace the Java CFG.
aschackmull Jan 20, 2026
42d7265
Java: Fix Cyclomatic complexity calculation.
aschackmull Feb 9, 2026
69a685b
Java: Fix RangeAnalysis/ModulusAnalysis.
aschackmull Feb 9, 2026
80fbfb0
Java: Fix switchcase guards.
aschackmull Feb 9, 2026
5ba4bbd
Java: Adjust BasicBlock-based qltests.
aschackmull Feb 10, 2026
f89160c
Java: Adjust idominance tests.
aschackmull Feb 16, 2026
859f59f
Java: Accept guards test changes for revised switch CFG.
aschackmull Feb 10, 2026
2a3eed2
Java: Accept test changes due to pruned CFG, after-nodes, and reduced…
aschackmull Feb 10, 2026
8feecdf
Java: Accept new CFG nodes.
aschackmull Feb 10, 2026
b71509a
Java: Fix instanceof-disjunction.
aschackmull Feb 11, 2026
547fbc9
Java: Exclude ExprStmt consistent with SwitchCase.getRuleExpression().
aschackmull Feb 11, 2026
e4d1c0f
Java: Fix reference to entry node.
aschackmull Feb 12, 2026
89f3754
Java: Remove test. Flexible constructors need AST-based tests, which …
aschackmull Feb 12, 2026
21663eb
Java: Accept new locations for SSA definitions.
aschackmull Feb 12, 2026
4170804
Java: Accept dispatch precision improvement.
aschackmull Feb 12, 2026
6478ee7
Java: Fix enhancedForEarlyExit implementation.
aschackmull Feb 12, 2026
30d69d7
Java: Accept new TP in NullMaybe.
aschackmull Feb 12, 2026
53c3481
Java: Accept removal of spurious reason (the alert stays).
aschackmull Feb 12, 2026
442e30a
Java: Accept reduced precision from no longer nesting completions in …
aschackmull Feb 12, 2026
a349b7c
Java: Accept revised CFG.
aschackmull Feb 13, 2026
49edbbd
Java: Remove obsolete tests - false successors are no longer special.
aschackmull Feb 16, 2026
6830c65
Java: Enable Cfg consistency checks.
aschackmull Feb 16, 2026
a65045c
Java: Adjust switch case guards test.
aschackmull Feb 16, 2026
3534872
Java: Add change note.
aschackmull Feb 18, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions java/ql/consistency-queries/CfgConsistency.ql
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
import java
import ControlFlow::Consistency
16 changes: 16 additions & 0 deletions java/ql/lib/change-notes/2026-02-18-cfg.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
---
category: breaking
---
* The Java control flow graph (CFG) implementation has been completely
rewritten. The CFG now includes additional nodes to more accurately represent
certain constructs. This also means that any existing code that implicitly
relies on very specific details about the CFG may need to be updated.
The CFG now only includes the nodes that are reachable from the entry point.
Additionally, the following breaking changes have been made:
- `ControlFlowNode.asCall` has been removed - use `Call.getControlFlowNode` instead.
- `ControlFlowNode.getEnclosingStmt` has been removed.
- `ControlFlow::ExprNode` has been removed.
- `ControlFlow::StmtNode` has been removed.
- `ControlFlow::Node` has been removed - this was merely an alias of
`ControlFlowNode`, which is still available.
- Previously deprecated predicates on `BasicBlock` have been removed.
4 changes: 2 additions & 2 deletions java/ql/lib/printCfg.ql
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ external int selectedSourceColumn();

private predicate selectedSourceColumnAlias = selectedSourceColumn/0;

module ViewCfgQueryInput implements ViewCfgQueryInputSig<File> {
module ViewCfgQueryInput implements ControlFlow::ViewCfgQueryInputSig<File> {
predicate selectedSourceFile = selectedSourceFileAlias/0;

predicate selectedSourceLine = selectedSourceLineAlias/0;
Expand All @@ -42,4 +42,4 @@ module ViewCfgQueryInput implements ViewCfgQueryInputSig<File> {
}
}

import ViewCfgQuery<File, ViewCfgQueryInput>
import ControlFlow::ViewCfgQuery<File, ViewCfgQueryInput>
96 changes: 0 additions & 96 deletions java/ql/lib/semmle/code/java/Completion.qll

This file was deleted.

Loading
Loading