function calls: direct vs apply vs call vs bind (v40)

Revision 40 of this benchmark created on


Setup

var f = function(){
      return this;
    };
    
    var that = {};
    
    var bound = f.bind(that);

Test runner

Ready to run.

Testing in
TestOps/sec
direct
f();
ready
apply
f.apply(that);
ready
call
f.call(that);
ready
bind
bound();
ready

Revisions

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