Run details:
Mozilla/5.0 (Android 13; Mobile; rv:109.0) Gecko/118.0 Firefox/118.0
Firefox Mobile 118
Android
Mobile
one year ago
Test name Executions per second
for of: few items 7357372.0 Ops/sec
for of: many items 46319.8 Ops/sec
convert to array: few items 4022398.8 Ops/sec
convert to array: many items 27159.0 Ops/sec
native iterator: few items 6983534.5 Ops/sec
native iterator: many items 43834.4 Ops/sec
native iterator w/ size: few items 7192769.5 Ops/sec
native iterator w/ size: many items: 43702.1 Ops/sec
Script Preparation code:
Tests:
  • for of: few items

  • for of: many items

  • convert to array: few items

  • convert to array: many items

  • native iterator: few items

  • native iterator: many items

  • native iterator w/ size: few items

  • native iterator w/ size: many items: