Run details:
Mozilla/5.0 (Linux; Android 6.0; HUAWEI GRA-L09 Build/HUAWEIGRA-L09) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/68.0.3440.91 Mobile Safari/537.36
Chrome Mobile 68
Android 6.0
Mobile
6 years ago
Test name Executions per second
int*int 673951.6 Ops/sec
int**2 1227524.4 Ops/sec
Math.pow(int,2) 402938.3 Ops/sec
float*float 676420.3 Ops/sec
float**2 1176775.4 Ops/sec
Math.pow(float, 2) 389120.6 Ops/sec
int*int*int*int*int 264219.0 Ops/sec
int**5 1208577.5 Ops/sec
Math.pow(int,5) 400797.8 Ops/sec
float*float*float*float*float 259824.0 Ops/sec
float**5 1178748.2 Ops/sec
Math.pow(float,5) 406090.7 Ops/sec
Script Preparation code:
Tests:
  • int*int

  • int**2

  • Math.pow(int,2)

  • float*float

  • float**2

  • Math.pow(float, 2)

  • int*int*int*int*int

  • int**5

  • Math.pow(int,5)

  • float*float*float*float*float

  • float**5

  • Math.pow(float,5)


;