Run details:
Mozilla/5.0 (iPhone; CPU iPhone OS 16_0 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/16.0 Mobile/15E148 Safari/604.1
Mobile Safari 16
iOS 16.0
Mobile
2 years ago
Test name Executions per second
.map(callback) - 1 000 elements 495706.2 Ops/sec
.fill(value) - 1 000 elements 591959.2 Ops/sec
.map(callback) - 10 000 elements 73498.8 Ops/sec
.fill(value) - 10 000 elements 84284.5 Ops/sec
.map(callback) - 100 000 elements 6959.0 Ops/sec
.fill(value) - 100 000 elements 8237.8 Ops/sec
Script Preparation code:
Tests:
  • .map(callback) - 1 000 elements

  • .fill(value) - 1 000 elements

  • .map(callback) - 10 000 elements

  • .fill(value) - 10 000 elements

  • .map(callback) - 100 000 elements

  • .fill(value) - 100 000 elements


;