문제

Can a page be, at the same time, in physical memory and in virtual memory?

If I ask for an address that's on virtual memory, will it always trigger a page fault? If the first question is true, then it should only trigger a page fault if the page is not also in physical memory. Is that right?

도움이 되었습니까?

해결책

Can a page be at the same time in physical memory and in virtual memory?

When you page out a memory block you need the space for other stuff, so it would make no sense to have it in RAM and in page file.

If I ask for an address that's on virtual memory, will it always trigger a page fault? If the first question is true, then it should only trigger a page fault if the page is not also in physical memory. Is that right?

Yes thats right. Pagefaults cause an interrupt. If you always had a pagefault when you access memory than you had only very little performace.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top