Latest virtual memory windows Weblinks:
- Re: how to get physical memory address from virtual memory address
Hari wrote: There isn't one. You haven't allocated any physical memory, so the kernel doesn't give you any. DS- Re: how to get physical memory address from virtual memory address
Correct, if by "valid" you mean "mapped and present" so that touching the page doesn't give rise to an exception. However, there can be mapped pages which are not present. Change or disappear temporarily (become not present).- Re: how to get physical memory address from virtual memory address
Of course, you are wrong. Virtual addresses /only/ have corresponding physical addresses when they are used in a memory reference. Pure "allocation" (malloc()) doesn't result in a memory reference, so no real address is assigned. (FWIW, this is why the OOM killer works the way it does - it kills processes that have allocated memory- Re: how to get physical memory address from virtual memory address
This is not a task that should be performed by the user-level process. You can't for example test the memory which is permanently mapped by kernel (which user-level process is not allowed to access). For memory diagnostics, tools specifically crafted for such tasks should be used (such as memtest86).- Re: how to get physical memory address from virtual memory address
What?? This is entirely incorrect. EVERY valid virtual address has an associated physical address. In the case of malloc-ed memory, that physical address will be in physical memory. Addressing the OP, while you are in user mode, the physical address can change at any time. The only reliable way to get the physical address isShipping now 1,399us for about Mapping the mouse buttons onto the keyboard in xfree86 this tutorial can help the otherwise useless windows and menu keys as virtual mouse buttons make a laptop keyboard more useful and comfortable by making good use of People hate oracle some of you had a few thoughts on this one My main grumble with graphics capability the machine is the Dstn is not very good at all- Re: how to get physical memory address from virtual memory address
Hari wrote: You have to do this in the kernel. Firstly, the page obviously has to be nailed down (unswappable). Otherwise it has no fixed physical address. When paged out, it has no address at all, and may get a different physical address each time it is paged out. You can do this using the get_user_pages() kernel function, which will
FREE NEWSLETTER
|
| Latest News, and Special Offers on Memory enter your name and email address here: |
|
|
|
|