use ThreadTree in thread buffer