Script Preparation code:
AخA
 
var a = 100000000;
Tests:
  • pow

     
    var tmp = Math.round((Math.random()*100000000));
    var i = 8;
    var tmp = tmp/Math.pow(10, i);
  • **

     
    var tmp = Math.round((Math.random()*100000000));
    var i = 8;
    var tmp = tmp/(10 ** i);
  • *

     
    var tmp = Math.round((Math.random()*100000000));
    var i = 8;
    while(i-- > 0){
                tmp = tmp/10;
    }
  • e to number

     
    var tmp = Math.round((Math.random()*100000000));
    var i = 8;
    var tmp = tmp/Number(10+'e'+i);
Rendered benchmark preparation results:

Suite status: <idle, ready to run>

Previous results

Experimental features:

  • Test case name Result
    pow
    **
    *
    e to number

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: 3 months ago)
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/99.0.4844.84 Safari/537.36
Chrome 99 on Windows
View result in a separate tab
Test name Executions per second
pow 37991288.0 Ops/sec
** 72940336.0 Ops/sec
* 19437200.0 Ops/sec
e to number 39124744.0 Ops/sec