开发者

Hardware virtualization - Hypervisor query

开发者 https://www.devze.com 2023-01-26 16:14 出处:网络
How will a hypervisor reflect a change whenever there occurs a change in the guest page table of the guest OS.

How will a hypervisor reflect a change whenever there occurs a change in the guest page table of the guest OS. How is the correspondence maintained between guest page mapping and shadow page mapping?

One way is write protecting the memory addresses. Whenever there will be write into a guest p开发者_如何学Cage table, there will be a appropriate handler that will ensure the corresponding change into the shadow page table. Can I have some more inputs in this area?


If the hardware supports nested paging, the guest OS manages its page tables with no hypervisor involvement other than faulting physical pages into the guest's address space. Otherwise, some sort of shadow page tables are required, but the implementations vary wildly. Some hypervisors trap and rewrite guest OS page fault handling instructions into hypercalls to lower the overhead of maintaining shadow page tables. Paravirtualization puts the burden on the guest kernel to handle this. Hardware virtualization without nested paging traps to the hypervisor on guest page fault, which is slower, but less bug-prone than software-only methods.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号