Use gethrtime from platform lib

Change-Id: Ieaca13f1cb8beb35aeb5d810770522afcdef4cc0