a quick timer in C++ to time function calls