Add clock to measure the running time.