initial commit for tree-based barrier