Run details:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/135.0.0.0 Safari/537.36
Chrome 135
Mac OS X 10.15.7
Desktop
one year ago
for ... of
9K/s
.reduce()
4K/s
regular for
3K/s
.filter().map()
1K/s
.flatMap()
1K/s
regular for, prefilled then trimmed
608/s
View exact numbers
Test name Executions per second
for ... of 8,912 Ops/sec
.reduce() 4,450 Ops/sec
regular for 2,551 Ops/sec
.filter().map() 1,435 Ops/sec
.flatMap() 1,274 Ops/sec
regular for, prefilled then trimmed 608 Ops/sec
HTML Preparation code:
Script Preparation code:
Tests: