Bluebird vs RSVP vs Native (v63)

Revision 63 of this benchmark created by badeend on


Description

A comparison of the two most highly performant promise implementations and the new native promises.

Preparation HTML

<script src="http://rsvpjs-builds.s3.amazonaws.com/rsvp-latest.js"></script>
<script src="https://cdn.jsdelivr.net/bluebird/latest/bluebird.js"></script>
<script>var BPromise = Promise.noConflict();
if ((Promise + "").indexOf("native") < 0) alert("not native promises");
</script>

Test runner

Ready to run.

Testing in
TestOps/sec
Bluebird deferred
// async test
function make() {
  return new BPromise(function (resolve, reject) {
      resolve(1)
  })
}

make().then(function (v) { return v+1; })
ready
RSVP deferred
// async test
function make() {
  var defer = RSVP.defer()

    defer.resolve()

  return defer.promise
}

make().then(function () { deferred.resolve() })
ready
Bluebird classic
// async test
function make() {
  return new BPromise(function (resolve, reject) {
      resolve(1)
  })
}

make().then(function (v) { return v+1; })
ready
RSVP classic
// async test
function make() {
  return new RSVP.Promise(function (resolve, reject) {
      resolve(1)
  })
}

make().then(function (v) { return v+1; })
ready
Native Promises
function make() {
  return new Promise(function (resolve, reject) {
      resolve(1)
  })
}

make().then(function (v) { return v+1; })
ready

Revisions

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