Quickest way to a UNIX Date (v33)

Revision 33 of this benchmark created by ghjghj on


Description

Pits ES5.1 Date.now() against backwards-compatible alternatives.

Test runner

Ready to run.

Testing in
TestOps/sec
Date.now() (ES5.1, IE9+)
Date.now()
ready
new Date().getTime() (All Browsers)
new Date().getTime()
ready
+new Date() (All Browsers)
+new Date()
ready
+new Date (All Browsers)
+new Date
ready
Number(new Date()) (All Browsers)
Number(new Date())
ready
Date.parse(new Date()) (All Browsers)
Date.parse(new Date())
ready
new Date/1E3|0
new Date/1E3|0
ready

Revisions

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