Fast, high resolution timer library for recording performance metrics