Suddenly experiencing massive lag, seems to be Directory.getEntries and/or GC


#1

hey all,

today i started experiencing massive (1-5 seconds) lag / hangs / unresponsiveness in Atom. i didn’t update anything that i’m aware of recently. i did enable the spell checker for source.js files running Atom 1.8.0 on OSX 10.10.5 (Yosemite).

i’ve tried restarting the app and the entire machine to no effect.

the most consistent hang is when expanding a directory in the tree view, though i’m also experiencing intermittent several second lag typing, scrolling, closing files, etc…

i ran a profile during a hang expanding a directory and it seems (i’m a novice with js profiling) that Directory.getEntries is eating 600ms and the GC another 500ms (see first screen shot in image).

i ran another profile during a scrolling lag and the 500ms GC is there again (see second screen shot in image).

i also noticed that there are errors at startup related to a submodule i recently added to the project repo (git) (see third screen shot in image).

i’ve yet to look into those.

screen shots (joined into one image because i can’t post multiple images?! screen shots can be really helpful when you’re doing support…):

i’m on a maxed-out MacBook Pro with 16G RAM, and the OS doesn’t show any memory pressure.

  • anyone have any idea why the GC is going mad like that all of a sudden?
  • or any ideas what else it could be?
  • any caches or other things that might have got messed up that i can nuke?

thanks in advance, Neil.


#2

Does the hanging occur when you start Atom from the command line with atom --safe?


#3

the hanging has since stopped, seemingly of it’s own accord :confused:

thanks for the suggestion, if it reoccurs i will try that out and report back.


#4

Safe mode is an important first step because it shuts down all community packages and just loads stock Atom. If you’re seeing an inexplicable error, you can use it to figure out whether the error is coming from the editor or from a package.


#5

thanks, that’s really useful.