Add process tree utility functions
Add minimal copyright headers