I just modified 3000 txt files with regex replacement.
The app is so slow and takes so much resources to save my modifications, and for what? text files?
Tell me what is the problem. Idk where to ask a dev to look into it.
There are also other instances where I close ALL 3000 tabs and takes forever.
Every save takes averagely 1.15 seconds, multiplied for 3000 it will take 1 HOUR to save them all. bruh
Painfully slow mass saving
Find in Files opens each affected text file. Each file is tokenized for syntax highlighting and plugins such as SublimeLinter or LSP might jump in to provide code intelligence or diagnostics, each of which might require some resources depending on contents’ size, syntax and overall projects complexity. Information handled for open files is way more than just an array of chars.
Saving files should be very fast. Plugins such as LSP or formatters however may intercept that process to take action on content before actually saving. Such operations may be expensive.
A disk usage of 46.8MB/s indicates your SSD/HDD to already be quite busy, either saving files or still running the “find and replace” or any other operation in background. Modifying files might also cause ST’s indexer to jump in, updating symbol tables.
Note that even on SSDs you can’t expect 7GB/s writing tons of small files as command queues and IOPS are the limiting factor then.
- no other process doing while saving, the app is frozen anyway while saving is in progress, i couldnt even if i wanted.
- LSP not installed, nor any other plugins, i already tried raw with no plugins, same. i can’t code anyway except regex.
- idk if the app has a default formatter, i didnt enable or installed any .
It seems the find and replace process itself, which runs synchronously in UI thread freezing whole UI.
At least on my end whole UI is frozen in recent ST4178, while attempting to remove all comments from linux kernel sources. .
That’s indeed not ideal. Sitting here for about 15mins already, waiting for completion. Ok, these are 30k files with millions of operations. Maybe takes a day or two.
I forgot to menzion a thing, the more mass modifications with regex I do the more slow the mass saving becomes. So at the beginning is decently fast, after 30+ mass modifications u will see the difference.