Date.now vs Date.getTime (v13)

Revision 13 of this benchmark created on


Setup

Date.nowPolyfill=function(){return new Date().getTime()};

Test runner

Ready to run.

Testing in
TestOps/sec
Date.now();
var foo = Date.now();
ready
Date.getTime()
var foo = new Date().getTime();
ready
+new Date
var foo = +new Date;
ready
Date.nowPolyfill
var foo = Date.nowPolyfill();
ready

Revisions

You can edit these tests or add more tests to this page by appending /edit to the URL.