Run details:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/68.0.3418.2 Safari/537.36
Chrome 68
Windows
Other
6 years ago
Test name Executions per second
float multiply 3182306.2 Ops/sec
bigInt multiply 2377273.8 Ops/sec
float compare 3176812.2 Ops/sec
bigInt compare 3118973.8 Ops/sec
string compare 3374900.0 Ops/sec
float greater 3184777.8 Ops/sec
bigint greater 2935428.8 Ops/sec
string greater 3397046.5 Ops/sec
toString bigInt 1942719.5 Ops/sec
toString float 5512636.5 Ops/sec
toFloat bigInt 2750533.0 Ops/sec
toFloat string 2095405.4 Ops/sec
Script Preparation code:
Tests:
  • float multiply

  • bigInt multiply

  • float compare

  • bigInt compare

  • string compare

  • float greater

  • bigint greater

  • string greater

  • toString bigInt

  • toString float

  • toFloat bigInt

  • toFloat string