Run details:
Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:98.0) Gecko/20100101 Firefox/98.0
Firefox 98
Ubuntu
Desktop
2 years ago
Test name Executions per second
Number (with string integer) 15702560.0 Ops/sec
Unary + (with string integer) 31851690.0 Ops/sec
parseInt (with string integer) 17834630.0 Ops/sec
Number (with string float) 2368161.0 Ops/sec
Unary + (with string float) 2459959.0 Ops/sec
parseInt (with string float) 4456438.0 Ops/sec
Number (with integer) 47454170.0 Ops/sec
Unary + (with integer) 1185195000.0 Ops/sec
parseInt (with integer) 47792300.0 Ops/sec
Number (with float) 51047090.0 Ops/sec
Unary + (with float) 1617298000.0 Ops/sec
parseInt (with float) 42157980.0 Ops/sec
Number (with NaN) 25356770.0 Ops/sec
Unary + (with NaN) 1554607000.0 Ops/sec
parseInt (with NaN) 38820460.0 Ops/sec
Tests:
  • Number (with string integer)

  • Unary + (with string integer)

  • parseInt (with string integer)

  • Number (with string float)

  • Unary + (with string float)

  • parseInt (with string float)

  • Number (with integer)

  • Unary + (with integer)

  • parseInt (with integer)

  • Number (with float)

  • Unary + (with float)

  • parseInt (with float)

  • Number (with NaN)

  • Unary + (with NaN)

  • parseInt (with NaN)