Tests:
  • splice

    AخA
     
    var a = [ "hello", "hello", "hello", "hello", "hello", "hello", "hello", "hello", "hello", "hello" ];
    var b = [ "hello", "hello", "hello", "hello", "hello", "hello", "hello", "hello", "hello", "hello" ];
    var other = b.splice(0, 0, ...a);
  • concat

     
    var a = [ "hello", "hello", "hello", "hello", "hello", "hello", "hello", "hello", "hello", "hello" ];
    var b = [ "hello", "hello", "hello", "hello", "hello", "hello", "hello", "hello", "hello", "hello" ];
    var other = b.concat(a);
  • spread

     
    var a = [ "hello", "hello", "hello", "hello", "hello", "hello", "hello", "hello", "hello", "hello" ];
    var b = [ "hello", "hello", "hello", "hello", "hello", "hello", "hello", "hello", "hello", "hello" ];
    var other = [...a, ...b]
Rendered benchmark preparation results:

Suite status: <idle, ready to run>

Previous results

Experimental features:

  • Test case name Result
    splice
    concat
    spread

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: 2 years ago)
Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/112.0.0.0 Safari/537.36
Chrome 112 on Linux
View result in a separate tab
Test name Executions per second
splice 12898115.0 Ops/sec
concat 12170247.0 Ops/sec
spread 25598410.0 Ops/sec