cleaning up code, adding execution time check.

Still debating whether I want to add more introspection. Execution time
checks suggest that typical script calls run around 15-25ms, so still
plenty of room to add functionality.