Thread Safety Analysis: implement review suggestions from Aaron Ballman.

llvm-svn: 209847
This commit is contained in:
DeLesley Hutchins
2014-05-29 21:24:16 +00:00
parent 286ae08e7d
commit b603192124
4 changed files with 38 additions and 27 deletions

View File

@@ -725,7 +725,7 @@ void SExprBuilder::exitCFGBlockBody(const CFGBlock *B) {
if (N == 1) {
til::BasicBlock *BB = *It ? lookupBlock(*It) : nullptr;
// TODO: set index
unsigned Idx = BB->findPredecessorIndex(CurrentBB);
unsigned Idx = BB ? BB->findPredecessorIndex(CurrentBB) : 0;
til::SExpr *Tm = new (Arena) til::Goto(BB, Idx);
CurrentBB->setTerminator(Tm);
}