Run details:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/101.0.4951.54 Safari/537.36
Chrome 101
Windows
Desktop
2 years ago
Test name Executions per second
Set spread num 91306.1 Ops/sec
Array from set 101752.3 Ops/sec
Filter 9096.5 Ops/sec
Create Set 103021.2 Ops/sec
For 8845.9 Ops/sec
Set array 54885.3 Ops/sec
Array set string 100808.7 Ops/sec
For string 4081.6 Ops/sec
Create set string 55774.5 Ops/sec
Filter string 2372.8 Ops/sec
Filter string small 126711.9 Ops/sec
Filter number small 130579.9 Ops/sec
Create set small string 375123.4 Ops/sec
Create set small 449982.4 Ops/sec
For string small 34452.4 Ops/sec
For small 53187.5 Ops/sec
Array set small string 390905.3 Ops/sec
Array set small 486182.2 Ops/sec
Spread set small 552158.6 Ops/sec
Spread set small string 482450.3 Ops/sec
Script Preparation code:
Tests:
  • Set spread num

  • Array set small

  • Array set small string

  • For small

  • For string small

  • Create set small

  • Create set small string

  • Filter number small

  • Filter string small

  • Filter string

  • Create set string

  • For string

  • Array set string

  • Set array

  • For

  • Create Set

  • Filter

  • Array from set

  • Spread set small

  • Spread set small string


;