Windows 10 high memory usage when screen is off
After trying out a lot of different settings and configurations, it appears the problem is related to the settings of my secondary monitor.
The monitor has three different video inputs (VGA, DVI and HDMI) and it was set to automatically detect the correct input, based on which is connected. Since I only use HDMI, I have changed the input detection to “manual” and set it to HDMI. I do no longer run out of memory now.
It is remarkable though that I did not have this problem on Windows 7 and Windows 8.1, but I do have it on Windows 10.
ok, In the trace I can see that the function ntoskrnl.exe!SmKmStoreHelperWorker
of the Kernel starts to allocate memory.
I discovered this last week on sysinternals.
I've asked Microsoft about it and the answer is that this is by design. It is related to System Memory compression.
In the announcement of Windows 10 Build 10525, Microsoft explained it a bit:
In Windows 10, we have added a new concept in the Memory Manager called a compression store, which is an in-memory collection of compressed pages. This means that when Memory Manager feels memory pressure, it will compress unused pages instead of writing them to disk. This reduces the amount of memory used per process, allowing Windows 10 to maintain more applications in physical memory at a time. This also helps provide better responsiveness across Windows 10. The compression store lives in the System process’s working set. Since the system process holds the store in memory, its working set grows larger exactly when memory is being made available for other processes. This is visible in Task Manager and the reason the System process appears to be consuming more memory than previous releases.
So instead of writing memory data to the pagefile it compresses them. And this compressed memory is shown in the System process.