array methods

Benchmark created on


Setup

const e = []
const f = new Array(1e5).fill(0)

Test runner

Ready to run.

Testing in
TestOps/sec
Do nothing
e[0]
f[0]
ready
Call methods on empty
e.filter(x=>true)
ready
Call methods on full
f.filter(x=>true)
ready
Call methods on empty but check before
e.length === 0 || e.filter(x=>true)
ready

Revisions

You can edit these tests or add more tests to this page by appending /edit to the URL.