performance optimization
using ticker to get a more accurate timing