diff options
Diffstat (limited to 'cfg/CFGNode.java')
-rw-r--r-- | cfg/CFGNode.java | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/cfg/CFGNode.java b/cfg/CFGNode.java index 5ce39b5..41f2c9c 100644 --- a/cfg/CFGNode.java +++ b/cfg/CFGNode.java @@ -10,13 +10,15 @@ public class CFGNode { private Node instruction; private ArrayList<CFGNode> sources; private ArrayList<CFGNode> dests; - protected Set<String> reaching; - protected Set<String> liveness; + public Set<String> defs; + public Set<String> reaching; + public Set<String> liveness; public CFGNode(Node instruction) { this.instruction = instruction; this.sources = new ArrayList<>(); this.dests = new ArrayList<>(); + this.defs = new HashSet<>(); this.reaching = new HashSet<>(); this.liveness = new HashSet<>(); } @@ -70,4 +72,8 @@ public class CFGNode { return Collections.unmodifiableSet(this.liveness); } + public Set<String> getDefinitions() { + return Collections.unmodifiableSet(this.defs); + } + } |