Add Simon's Visitor pattern code

Thanks Simon! <3
Initial prototype of profiling functionality