ProgQuery is a system to extract useful syntactic and semantic information from source code programs and store it in a graph database for posterior querying.
MIT License
15
stars
4
forks
source link
Adding a feature to get the Control Flow Graph (CFG) using stored information from javac and integrate it in the final graph. #3
Adding a new feature to incorporate a new fundamental data structure into the unified final graph stored in Neo4j:
This data structure is the Control Flow Graph (CFG) used to model the order and the flow in the execution of the sentences of each block defined in the analized program. More concretely, the new graph consists in :
New edge type called NEXT, to relate statements, each one with the following that will be unconditionally executed.
New edge type called CONDITION, to relate statements with boolean expressions that control the execution of the next statements.
Two new edge types, TRUE and FALSE to relate statements, in the cases where the execution of the following sentences is conditional.
(maybe the switch statement is easier with more)
Only one new node type to represent the end of the methods called METHOD_END. Technically its type is STATEMENT (although it is a invisible one) and it is located after the last sentence (even if this sentence is a RETURN).
Two new edge types, ENTRY and EXIT, relating blocks with the starting and the end statement of each method.
Adding a new feature to incorporate a new fundamental data structure into the unified final graph stored in Neo4j: