compute elapsed time without altering public api