I am working on relatively small (100-300 lines) Javascript files in Eclipse and periodically it gets really upset about some piece of code and pops up this error every time
I was getting same error with gc overhead limit exceeded description in details section of error. To take action on it I have added following in configuration and issue resolved.