Added in time measurement code.