Skip to content

Commit

Permalink
Optimize locking
Browse files Browse the repository at this point in the history
  • Loading branch information
ProfFan committed Apr 6, 2022
1 parent 027a4a5 commit af1dedb
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions gtsam/inference/ClusterTree-inst.h
Original file line number Diff line number Diff line change
Expand Up @@ -148,15 +148,9 @@ struct EliminationData {
}
// Set up BayesTree parent and child pointers
if (parentData) {
#ifdef GTSAM_USE_TBB
parentData->writeLock->lock();
#endif
if (parentData->parentData) // If our parent is not the dummy node
bayesTreeNode->parent_ = parentData->bayesTreeNode;
parentData->bayesTreeNode->children.push_back(bayesTreeNode);
#ifdef GTSAM_USE_TBB
parentData->writeLock->unlock();
#endif
}
}

Expand Down

0 comments on commit af1dedb

Please sign in to comment.