Improved HTime implementation.