Script Preparation code:
x
 
class A {
  execute() {
    
  }
  
  callback1() {}
  
  callback2() {}
}
window.a = new A();
Tests:
  • bind

     
    a.execute = function () {
      let bound1 = this.callback1.bind(this);
      let bound2 = this.callback2.bind(this);
        
      bound1();
      bound2();
    }
    a.execute();
  • arrow

     
    a.execute = function () {
      let bound1 = () => this.callback1();
      let bound2 = () => this.callback2();
        
      bound1();
      bound2();
    }
    a.execute();
Rendered benchmark preparation results:

Suite status: <idle, ready to run>

Previous results

Experimental features:

  • Test case name Result
    bind
    arrow

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: one year ago)
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/113.0.0.0 Safari/537.36 Edg/113.0.1774.57
Chrome 113 on Windows
View result in a separate tab
Test name Executions per second
bind 2366235.5 Ops/sec
arrow 2346935.8 Ops/sec