Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

After saving the file, the memory usage will increase abnormally #2587

Open
luoluo74751 opened this issue Oct 17, 2024 · 6 comments
Open

After saving the file, the memory usage will increase abnormally #2587

luoluo74751 opened this issue Oct 17, 2024 · 6 comments

Comments

@luoluo74751
Copy link

Version, Operating system
windows10

Describe the bug
After saving the file, the memory usage will increase abnormally
After I save my files, the entire software's memory usage keeps increasing as if there is no upper limit
before:
image
use save:
image

thank!

@dbwiz
Copy link

dbwiz commented Oct 17, 2024

Another user's test:
Windows 10, 1.2.0 (nolatex, installed). 500MB CTB

  1. Open CTB: task manager states 48MB memory
  2. minor edits, manual save: now 221 MB
  3. minor edits, manual save, now 348 MB
  4. minor edits, manual save, now 339 MB
  5. minor edits, manual save, now 338 MB.

It seems to top out at around 340MB for me.

@luoluo74751
Copy link
Author

Another user's test: Windows 10, 1.2.0 (nolatex, installed). 500MB CTB

  1. Open CTB: task manager states 48MB memory
  2. minor edits, manual save: now 221 MB
  3. minor edits, manual save, now 348 MB
  4. minor edits, manual save, now 339 MB
  5. minor edits, manual save, now 338 MB.

It seems to top out at around 340MB for me.

oh... but it seems to top out 800MB for me,maybe i save many pictures?

@luoluo74751
Copy link
Author

and my code level is very poor,so i cant find its wrong,,,,,,,

@luoluo74751
Copy link
Author

emmm...
image

@dbwiz
Copy link

dbwiz commented Oct 24, 2024

As a follow up to my previous post on this item, I decided to log memory usage every 15 mins with a powershell script which I've been annotating over the last couple days. My usage is typically constant throughout the day, with CT left open while the computer sleeps, restarting CT maybe every week or so. I've found while the RAM usage does balloon out from time to time, the app also releases memory at intervals. It maxed at about 4.5G, later dropped to 240MB without prompting. I have 2 hour backup interval and the changes do not seem to be connected to that.

I'm perfectly comfortable with this usage and do not have an issue with this. Windows 10, 1.2.0 nolatex install.

@giuspen
Copy link
Owner

giuspen commented Oct 28, 2024

The reason for the memory increase at save time is that after saving the file the new file is re-parsed to ensure all is good before then rotating the backups.
The main cause of memory usage is currently the undo/redo state machine of the rich text nodes and that is something I will work on soon.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants