diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2018-08-02 17:33:11 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2018-08-02 17:33:11 +0000 |
commit | c7e70c433efc6953dc3888b9fbf9f3512d7da2b0 (patch) | |
tree | 27425930fc0c91650a7f3527fcac8e0f92907b90 /lib/Analysis/CFGStmtMap.cpp | |
parent | 486754660bb926339aefcf012a3f848592babb8b (diff) |
Diffstat (limited to 'lib/Analysis/CFGStmtMap.cpp')
-rw-r--r-- | lib/Analysis/CFGStmtMap.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/lib/Analysis/CFGStmtMap.cpp b/lib/Analysis/CFGStmtMap.cpp index 19b80191f7a77..3eed0d52f848a 100644 --- a/lib/Analysis/CFGStmtMap.cpp +++ b/lib/Analysis/CFGStmtMap.cpp @@ -24,7 +24,7 @@ static SMap *AsMap(void *m) { return (SMap*) m; } CFGStmtMap::~CFGStmtMap() { delete AsMap(M); } -CFGBlock *CFGStmtMap::getBlock(Stmt *S) { +CFGBlock *CFGStmtMap::getBlock(Stmt *S) { SMap *SM = AsMap(M); Stmt *X = S; @@ -53,17 +53,17 @@ static void Accumulate(SMap &SM, CFGBlock *B) { Optional<CFGStmt> CS = CE.getAs<CFGStmt>(); if (!CS) continue; - + CFGBlock *&Entry = SM[CS->getStmt()]; // If 'Entry' is already initialized (e.g., a terminator was already), // skip. if (Entry) continue; - + Entry = B; - + } - + // Look at the label of the block. if (Stmt *Label = B->getLabel()) SM[Label] = B; @@ -82,7 +82,7 @@ CFGStmtMap *CFGStmtMap::Build(CFG *C, ParentMap *PM) { SMap *SM = new SMap(); // Walk all blocks, accumulating the block-level expressions, labels, - // and terminators. + // and terminators. for (CFG::iterator I = C->begin(), E = C->end(); I != E; ++I) Accumulate(*SM, *I); |