I'm running Mathematica 12.1.1 on my Windows 10 laptop (Dell Latitude E5550 with Intel iCore 5, 8 GB RAM). My MMA sessions tend to be very long, sometimes extending on over days and weeks, interrupted by hibernation and wakeup. I develop software that uses a lot of graphical output such as ArrayPlot[] of matrices size 300x300 or so.
The stability is good, but the MMA Frontend always slows down over time. In heavy use, the slowdown becomes already noticeable within a single working day, i.e., before I hibernate the laptop at the end of the working day. The slowdown is most obvious when editing or typing commands and I sometimes reach the point that it takes the Frontend a second or so to display character after character when quickly typing a new command or line in a Module[]. Quitting and restarting MMA is then the only option (ClearAll["`*"] or even Quit[] and kernel restart doesn't help), but it takes me about 10 minutes to reload all notebooks and definitions and resume work, hence I'm hesitant to do so too often.
I usually have about 10 to 15 notebooks open, but normally I either save and close notebooks with lots of figure output, or else overwrite them on each rerun of the code I'm testing. I monitor the Frontend and Kernel memory which both keep climbing steadily, but not to the point that they consume more than 1 GB or so, hence just a small fraction of my total RAM. I already set $HistoryLength=150 to prevent the command history from accumulating.
Can anybody tell me what's the reason of the slowdown (memory leaks, excessive number of variables to look up in the automatic variable suggestion/completion function, stale file handles, memory page faults, or a bug in the Frontend....)? Any suggestions how to better monitor my session or find/remove the root cause of the slowdown?
Thanks, Ron