Question Is virtual memory causing low FPS if being used by a game?

Oct 9, 2020
22
0
10
0
Imagining someone has 4gb RAM and a 1440p monitor (So It's absolutely horrible for playing games) & uses virtual memory on SSD/HDD so games won't crash, if it is slower & not real memory does that mean It will affect FPS?
How much does it affect? I mean how different is Virtual memory from real memory?
 

boju

Titan
Ambassador
Well a system needing to access virtual memory too often can cause performance issues, hanging, components (cpu, gpu (frame rates compromised) etc) having to wait for data to be transferred from a slow source. An 2.5" SSD would be a whole lot better speed wise (Even better for Nvme type SSDs) for virtual memory than a hdd but in comparison to having data already in system ram or Vram is next level.
 

Pinhedd

Champion
Moderator
Imagining someone has 4gb RAM and a 1440p monitor (So It's absolutely horrible for playing games) & uses virtual memory on SSD/HDD so games won't crash, if it is slower & not real memory does that mean It will affect FPS?
How much does it affect? I mean how different is Virtual memory from real memory?
Short answer: yes

Long answer:

What you're describing isn't called virtual memory, it's called page swapping.

Page swapping is a technique used by operating systems to evict infrequently used process memory from physical memory and store it to a location in secondary storage, either a swap file on a partition or a dedicated swap partition. This process is transparent, processes are not aware when chunks of their memory are swapped out, and are not aware when a swapped chunk is brought back in.

Virtual memory is a related memory management technique that gives a process the illusion that it has the entirety of the computer's address space to itself. Memory is referenced by the process in terms of virtual addresses, and then put through a translation mechanism to generate a physical address. If a process references a virtual address that is currently swapped out, the operating system intervenes and brings that memory from the swap volume back into physical memory at a new location before allowing the process to proceed.

Virtual memory is always used on modern operating systems, it cannot be turned off. It's essential for process security (processes cannot read or write to one another's memory without permission), efficiency (shared system components are only present in memory once), preventing poorly written programs from hogging resources, and much more. Page swapping is not strictly necessary, but page swapping algorithms are mature enough that its best to just leave it enabled.
 

ASK THE COMMUNITY