esnext/es6-arrow-function — pull request #8 by drslump (2014-12-13 12:47:23+00:00)
Title: PERF: Avoid visiting identifiers outside arrow functions

Identifiers must be visited to handle `arguments` but since they are so common the visitor is being called to do nothing most of the time. This change moves the visiting logic for the body of an arrow function to a separate visitor, allowing the traversal to skip the call when it's not needed.

The results I'm getting are roughly **a x10 speed increase** when parsing things like underscore or jQuery:

Benchmarking...
current x 24.79 ops/sec ±1.71% (46 runs sampled)
0.6.2 x 1.91 ops/sec ±8.78% (9 runs sampled)

Following this logic, perhaps there is even more room for optimization by inlining the detection of `this` using a delegated visitor. However I don't think that'll make a huge difference and the code would become harder to understand.