]> granicus.if.org Git - llvm/commit
[DDG] Data Dependence Graph - Root Node
authorBardia Mahjour <bmahjour@ca.ibm.com>
Tue, 1 Oct 2019 19:32:42 +0000 (19:32 +0000)
committerBardia Mahjour <bmahjour@ca.ibm.com>
Tue, 1 Oct 2019 19:32:42 +0000 (19:32 +0000)
commit4c48a601af751593d28c4a9224aabae5cf1b92d6
tree0c3bb4789dafa9610afaafcec0a12af590d59cac
parente536ca663f9d3d9c9fc413f2f48e1801902c44ac
[DDG] Data Dependence Graph - Root Node

Summary:
This patch adds Root Node to the DDG. The purpose of the root node is to create a single entry node that allows graph walk iterators to iterate through all nodes of the graph, making sure that no node is left unvisited during a graph walk (eg. SCC or DFS). Once the DDG is fully constructed it will have exactly one root node. Every node in the graph is reachable from the root. The algorithm for connecting the root node is based on depth-first-search that keeps track of visited nodes to try to avoid creating unnecessary edges.

Authored By: bmahjour

Reviewer: Meinersbur, fhahn, myhsu, xtian, dmgreen, kbarton, jdoerfert

Reviewed By: Meinersbur

Subscribers: ychen, arphaman, simoll, a.elovikov, mgorny, hiraditya, jfb, wuzish, llvm-commits, jsji, Whitney, etiotto, ppc-slack

Tag: #llvm

Differential Revision: https://reviews.llvm.org/D67970

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@373386 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/Analysis/DDG.h
include/llvm/Analysis/DependenceGraphBuilder.h
lib/Analysis/DDG.cpp
lib/Analysis/DependenceGraphBuilder.cpp
test/Analysis/DDG/root-node.ll [new file with mode: 0644]