Run details:
Mozilla/5.0 (Linux; Android 10; K) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/125.0.0.0 Mobile Safari/537.36
Chrome Mobile 125
Android
Mobile
2 years ago
Benchmark.js
Set length to zero
6K/s
Just instantiate new array
5K/s
Splice
5K/s
Pop all values
4K/s
View exact numbers
Test name Executions per second
Set length to zero 5,701 Ops/sec
Just instantiate new array 5,432 Ops/sec
Splice 4,854 Ops/sec
Pop all values 3,620 Ops/sec
Tests: