More tree build refactor towards non-leaf sources.