add some timing code