Convert some of proc's functionality to use psutil

Recommend diff'ing with whitespace ignored (add `?w=0` to URL).

This removes a bunch of handwritten code in favor of a cross-platform library that already implements most of what we need.