Comment on Games on my PC start stuttering pretty badly when they aren't the active window for a while. Have to close the game and restart to resolve the stuttering issue. What exactly is causing this?

Deestan@lemmy.world ⁨2⁩ ⁨days⁩ ago

Sounds like your computer has a bit lower RAM than it needs, in which case it “swaps”.

This means taking some memory that’s not been used for a while and writing it to disk, and using the now free RAM for what you are currently doing.

When starting a game, it likely swaps out browser memory to make room for the game. It loads all it needs into RAM to make the game run smooth.

When tabbing out of the game, it swaps game memory to disk and swaps in browser memory.

When going back to the game, it will swap game memory back in in bits and pieces. Turn around, the game needs to draw that door texture. That needs to be swapped back into RAM from disk. Slight stutter, then normal. Walk a bit further, it needs to play footstep sounds. Those needs to be fetched back in from disk. And so on.

Writing/reading from a HDD makes noise and vibration, since it’s internally a core of spinning disks with several small motors moving back and forth.

An SSD has no moving parts and will not make noise. Stutters will be shorter, but still happen.

Adding more RAM will reduce or remove the need to swap to disk in the first place, and is the most useful upgrade to alleviate the issue.

source
Sort:hotnewtop