I am implementing virtual memory in PINTOS running on x86 ,I want to know the minimum number of frames needed for a process on an x86 processor.
I found out that it depends on the maximum level of indirection supported by the underlying Instruction set architecture ,On x86 there is 1 level of indirection supported.
So 2 frames per process should be the minimum needed.
If the instruction size is more than 1byte long then it might cross page boundary and we will need 3 minimum frames.
Am I correct or is there more to deciding on the minimum number of frames to be given per process.
Thanks
Page directory – 1
Page table – 1
Instruction on a page boundary – 2
Source data on a page boundary – 2
Destination data on a page boundary – 2
So, 8 pages is what you may need for something like
REP MOVSW/D.