Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Improve performance and memory usage? #1896
I noticed that Esprima are approx 26% slower than the Cherow parser, and around 52% slower when it comes to parsing huge libraries (more than 10 000 lines of code)
I also compared against Acorn, and even on small libraries it seems that Acorn are faster in a few cases.
If I run the same tests over and over again the difference in performance between Acorn and Esprima are very clear. This for libraries such as Rollup, Angular 1.6 and even Esprima itself.
I further checked the memory usage, and for larger libraries such as TypeScript 2.6.2 and React 16, Esprima eat a lot of RAM. You can measure this yourself.
Any plans to improve this?
I come across this issue, and I think it's enough to run any online benchmark to get to the point.
As you can see.. Acorn is for the most part equal in performance except for mobile devices, but both seems to suffers from miserable performance on mobile devices and when parsing libraries like TypeScript (I may think it's around 90k line of code),