[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-discuss] Understanding the info pg command

From: Anton Petrov
Subject: [Qemu-discuss] Understanding the info pg command
Date: Sun, 11 Oct 2015 20:31:24 -0400

Hi all,

I am having trouble interpreting the output from the info pg command. Consider the example output below:

(qemu) info pg
VPN range     Entry                Flags            Physical page
[80000-803ff]  PDE[200]             ----A--UWP
  [80000-800ff]    PTE[000-0ff]    --------WP   00000-000ff
  [80100-80102]  PTE[100-102]  ---------P     00100-00102
  [80103-80103]  PTE[103]         ----A----P    00103
  [80104-80106]  PTE[104-106]  ---------P     00104-00106
  [80107-80107]  PTE[107]         ----A----P    00107
  [80108-80108]  PTE[108]         ---------P     00108
  [80109-8010b]  PTE[109-10b]  --------WP   00109-0010b
  [8010c-8010c]  PTE[10c]          ----A---WP  0010c
  [8010d-803ff]    PTE[10d-3ff]    --------WP   0010d-003ff
[80400-8dfff]  PDE[201-237]       -------UWP
  [80400-8dfff]  PTE[000-3ff]       --------WP   00400-0dfff
[fe000-fffff]  PDE[3f8-3ff]             -------UWP
  [fe000-fffff]  PTE[000-3ff]          --------WP   fe000-fffff

The first page table entry maps the virtual address range 0x80000 - 0x800FF. How is that possible? There is a one to one correspondence from a PTE to a physical page and given that a page is 4096 bytes, the range mapped has to be 0xFFF and not 0xFF as is the case here. It seems like only a part of the page is mapped, which makes no sense, either the whole page is mapped or none of it.

What is the meaning of the index used in the PDE and PTE labels? For the first PDE, PDE[200], what is 200? Is it the index within the page directory table, so in this case we're looking at the 200th entry? Does that index have the same meaning for the PTEs?

What is the meaning of the line below? The virtual address range mapped is 0, why even print an entry for this?
  [80103-80103]  PTE[103]         ----A----P    00103

Finally, what is the 'Physical page' column? Those can't be the hex addresses of the physical pages. Are they the ordinal numbers of the physical pages?

I did some Googling around and the only description of the output I got is this one: https://pdos.csail.mit.edu/6.828/2014/labguide.html (see towards the bottom of the page in the QEMU seciton). A search on the user mailing list archive for "info pg" returned nothing either.

Any and all help is greatly appreciated! Thank you!


reply via email to

[Prev in Thread] Current Thread [Next in Thread]