<commit_before># fastparallel [![Build Status](https://travis-ci.org/mcollina/fastparallel.svg?branch=master)](https://travis-ci.org/mcollina/fastparallel)

Zero-overhead parallel function call for node.js. Also supports each
and map!

Benchmark for doing 3 calls `setImmediate` 1 million times:

* non-reusable `setImmediate`: 1781ms
* `async.parallel`: 3484ms
* `async.each`: 2621ms
* `async.map`: 3054ms
* `neoAsync.parallel`: 2162ms
* `neoAsync.each`: 2156ms
* `neoAsync.map`: 2080ms
* `insync.parallel`: 10252ms
* `insync.each`: 2397ms
* `insync.map`: 9700ms
* `items.parallel`: 3725ms
* `parallelize`: 2928ms
* `fastparallel` with results: 2139ms
* `fastparallel` without results: 1957ms
* `fastparallel` map: 21022102ms
* `fastparallel` each: 1941ms

These benchmarks where taken via `bench.js` on node v4.2.2, on a MacBook
Pro Retina Mid 2014 (i7, 16GB of RAM).

If you need zero-overhead series function call, check out
[fastseries](http://npm.im/fastseries). If you need a fast work queue
check out [fastq](http://npm.im/fastq). If you need to run fast
waterfall calls, use [fastfall](http://npm.im/fastfall).

[![js-standard-style](https://raw.githubusercontent.com/feross/standard/master/badge.png)](https://github.com/feross/standard)

__The major difference between version 1.x.x and 2.x.x is the order of
results__, this is now ready to replace async in every case.

## Example for parallel call

```js
var parallel = require('fastparallel')({
  // this is a function that will be called
  // when a parallel completes
  released: completed,

  // if you want the results, then here you are
  results: true
})

parallel(
  {}, // what will be this in the functions<commit_msg>Typo in README.<commit_after># fastparallel [![Build Status](https://travis-ci.org/mcollina/fastparallel.svg?branch=master)](https://travis-ci.org/mcollina/fastparallel)

Zero-overhead parallel function call for node.js. Also supports each
and map!

Benchmark for doing 3 calls `setImmediate` 1 million times:

* non-reusable `setImmediate`: 1781ms
* `async.parallel`: 3484ms
* `async.each`: 2621ms
* `async.map`: 3054ms
* `neoAsync.parallel`: 2162ms
* `neoAsync.each`: 2156ms
* `neoAsync.map`: 2080ms
* `insync.parallel`: 10252ms
* `insync.each`: 2397ms
* `insync.map`: 9700ms
* `items.parallel`: 3725ms
* `parallelize`: 2928ms
* `fastparallel` with results: 2139ms
* `fastparallel` without results: 1957ms
* `fastparallel` map: 2102ms
* `fastparallel` each: 1941ms

These benchmarks where taken via `bench.js` on node v4.2.2, on a MacBook
Pro Retina Mid 2014 (i7, 16GB of RAM).

If you need zero-overhead series function call, check out
[fastseries](http://npm.im/fastseries). If you need a fast work queue
check out [fastq](http://npm.im/fastq). If you need to run fast
waterfall calls, use [fastfall](http://npm.im/fastfall).

[![js-standard-style](https://raw.githubusercontent.com/feross/standard/master/badge.png)](https://github.com/feross/standard)

__The major difference between version 1.x.x and 2.x.x is the order of
results__, this is now ready to replace async in every case.

## Example for parallel call

```js
var parallel = require('fastparallel')({
  // this is a function that will be called
  // when a parallel completes
  released: completed,

  // if you want the results, then here you are
  results: true
})

parallel(
  {}, // what will be this in the functions
{'fraction_non_alphanumeric': 0.12928994082840237, 'fraction_numerical': 0.04792899408284024, 'mean_word_length': 4.597682119205298, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 8, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6009031', 'n_tokens_mistral': 1263, 'n_tokens_neox': 1099, 'n_words': 357}