Script Preparation code:
x
 
function s(obj){}
function C1() { 
    this.c = 0;
}
C1.prototype.test = function () { 
    this.c++;
}
function C2() { 
    this.c = 0;
    this.test = function () { 
        this.c++;
    }
}
var c1 = new C1();
var c2 = new C2();
Tests:
  • c1.test();

     
    c1.test();
  • c2.test();

     
    c2.test();
Rendered benchmark preparation results:

Suite status: <idle, ready to run>

Previous results

Experimental features:

  • Test case name Result
    c1.test();
    c2.test();

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: 8 years ago)
Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/54.0.2840.59 Safari/537.36 OPR/41.0.2353.46
Opera 41 on Windows
View result in a separate tab
Test name Executions per second
c1.test(); 11010402.0 Ops/sec
c2.test(); 11176119.0 Ops/sec