Added some comments. Fixed the timing stuff.