s*i 发帖数: 388 | 1 比如,
int * p
在win7和linux下debug看到的值,比如0x12345678 ,是virtual memory address还是
physical address?
如果是vm addr,如何能够访问到physical addr?
thanks. |
h****e 发帖数: 2125 | 2
mlock() or mlockall()
【在 s*i 的大作中提到】 : 比如, : int * p : 在win7和linux下debug看到的值,比如0x12345678 ,是virtual memory address还是 : physical address? : 如果是vm addr,如何能够访问到physical addr? : thanks.
|
s*i 发帖数: 388 | 3 so u mean that addr we see during debug is vm addr? thanks
【在 h****e 的大作中提到】 : : mlock() or mlockall()
|
h****e 发帖数: 2125 | 4
of course
【在 s*i 的大作中提到】 : so u mean that addr we see during debug is vm addr? thanks
|
t****t 发帖数: 6806 | 5 what you saw is the address in segment. add the base address (invisible in
user space) in segment, you get linear address. linear address is translated
to physical address via page table (again invisible in user space).
i think it is impossible to get physical address from given segment address
in user space.
【在 s*i 的大作中提到】 : 比如, : int * p : 在win7和linux下debug看到的值,比如0x12345678 ,是virtual memory address还是 : physical address? : 如果是vm addr,如何能够访问到physical addr? : thanks.
|
t****t 发帖数: 6806 | 6 mlock and mlockall doesn't get you physical address at all.
【在 h****e 的大作中提到】 : : of course
|
D*******a 发帖数: 3688 | 7 unless there is a kernel exploit that gets you to ring 0...
translated
address
【在 t****t 的大作中提到】 : what you saw is the address in segment. add the base address (invisible in : user space) in segment, you get linear address. linear address is translated : to physical address via page table (again invisible in user space). : i think it is impossible to get physical address from given segment address : in user space.
|
g**w 发帖数: 969 | 8 在windows下,可以用windbg转换,还可以看physical address的内容
不过实在kernel debugger mode下
【在 s*i 的大作中提到】 : 比如, : int * p : 在win7和linux下debug看到的值,比如0x12345678 ,是virtual memory address还是 : physical address? : 如果是vm addr,如何能够访问到physical addr? : thanks.
|
a****l 发帖数: 8211 | 9 I doubt it is even possible for user applications, on modern advanced
operating systems.
【在 s*i 的大作中提到】 : 比如, : int * p : 在win7和linux下debug看到的值,比如0x12345678 ,是virtual memory address还是 : physical address? : 如果是vm addr,如何能够访问到physical addr? : thanks.
|
s****n 发帖数: 786 | 10 对没有MMU的处理器还是可能的。
【在 a****l 的大作中提到】 : I doubt it is even possible for user applications, on modern advanced : operating systems.
|
s*i 发帖数: 388 | 11 恩,以前开发嵌入式的时候用的uclinux的早期版本就没有mmu,裸搞mem addr
【在 s****n 的大作中提到】 : 对没有MMU的处理器还是可能的。
|