Math.floor vs Bitwise NOT

Benchmark created by manast on


Test runner

Ready to run.

Testing in
TestOps/sec
Math.floor()
Math.floor(89.938 / 293.3);
Math.floor(83784 / 9289.2);
Math.floor(7 / 60);
ready
Bitwise NOT
~~(89.938 / 293.3);
~~(83784 / 9289.2);
~~(7 / 60);
 
ready
Bitwise OR
89.938 / 293.3 | 0;
83784 / 9289.2 | 0;
7 / 60 | 0;
ready

Revisions

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

  • Revision 1: published by manast on