Is it possible to unpage all memory in Windows?

后端 未结 3 1991
伪装坚强ぢ
伪装坚强ぢ 2020-12-09 19:12

I have plenty of RAM, however, after starting and finishing a large number of processes, it seems that most of the applications\' virtual memory has been paged to disk, and

3条回答
  •  没有蜡笔的小新
    2020-12-09 19:57

    Well, it isn't hard to implement yourself. Use VirtualQueryEx() to discover the virtual addresses used by a process, ReadProcessMemory() to force the pages to get reloaded.

    It isn't likely to going to make any difference at all, it will just be your program that takes forever to do its job. The common diagnostic for slow reloading of pages is a fragmented paging file. Common on Windows XP for example when the disk hasn't been defragged in a long time and it was allowed to fill close to capacity frequently. The SysInternals' PageDefrag utility can help fix the problem.

提交回复
热议问题