[Github-comments] [geany/geany] Geany Locking up when typing or copying of text (#1540)

elextr notifications at xxxxx
Thu Aug 3 00:31:00 UTC 2017


> also nothing else on the laptop shows any signs of swapping locking up.

Ok, swapping is probably not happening since it will make everything slow.

> Within Windows its not until I start doing anything like entering text things lock up with the LF down the side.

Ok, so Geany hangs, but in a post above you say Scite says it has run out of memory and closes, is that what happens when you do the same (or reasonably similar) things with Scite?

Because if Scite is saying Scintilla is out of memory, then its likely that Scintilla in Geany is too, but Geany misses the error and just gets in an infinite loop instead.  That should be fixed if we can find it.   However there are not many contributors to Geany who use Windows, which is why I am continuing to ask your assistance. (I don't even have windows in the house)

> Do you really consider 250 MB - 300 MB as a ridiculously large file for 2017?

There should be no hard limit in Geany, but as I said above, if its running out of memory then thats the limit, nothing we can do.  So can you please be more specific about what you did so we can try to determine how much memory the things you do might take. 

Note its not always obvious what it takes.  For example when you are editing and you increase the buffer contents beyond its current memory size the buffer memory must be increased in size, which means temporarily there are two copies in memory, as a new bigger buffer is allocated, and the contents of the old one copied to the new one, before the old one is de-allocated.  And remember the buffer is already twice the size of the file since it has a second byte for each byte in the file for storing the styling information.  So adding one character can cause the memory usage to be temporarily four times the file size, or 1.2GB for the 300MB file, which is a significant part of the 4GB that a 32 bit application can address, just for the buffer, without all the supporting structures.  I don't know how much data memory 32 bit Windows allows, maybe its only 2GB.

This happens inside Scintilla and is potentially Scite's "out of memory" message, so if you provide details of what you did to crash Scite/hang Geany we can look at its potential usage.  Geany on Linux is a 64 bit program, so it will not run out of address space before real memory, and swapping kicks in which "hangs" the whole machine.

As @codebrainz said, Scintilla and Geany's use-case is for editing human source files, so its code is designed on that premise.  If it was designed specifically for large files it would probably be designed differently.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/issues/1540#issuecomment-319834878
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.geany.org/pipermail/github-comments/attachments/20170802/e34abcc0/attachment.html>


More information about the Github-comments mailing list