日期:2014-05-17  浏览次数:20823 次

od内存窗口 里面的 “类型”的这个选项的 映像和私有 有什么不同

od内存窗口 里面的 “类型”的这个选项的 映像和私有  有什么不同 
私有 是什么意思??



[img=http://www.52pojie.cn/forum.php?mod=attachment&aid=MTU0OTM4fDRlNDkzZTUyfDEzNTQ1OTczMjh8MjI1MzgzfDE3NTA1Mw%3D%3D&noupdate=yes][/img]
------解决方案--------------------
映像,是对应文件里的内容在内存里的吧。
私有,这块内存不能被其它进程访问。
下面是 Sysinternal 组件里 VMMap 帮助里的解释,OD 的帮助里应该也有吧。
[bold]Image[/bold]
The memory represents an executable file such as a .exe or .dll and has been loaded into a process by the image loader. It does not include images mapped as data files, which would be included in teh Mapped File memory type. Image mappings can include shareable memory like code. When data regions, like initialized data, is modified, additional private memory is created in the process. The Details column shows the file's path.
[bold]Private[/bold]
Private memory is memory allocated by VirtualAlloc and not suballocated either by the Heap Manager or the .NET run time. It cannot be shared with other processes, is charged against the system commit limit, and typically contains application data. 
------解决方案--------------------
映射是部分的内存应该是有文件对应的,也就是将文件映射到内存中,比如CreateFile->CreateFileMapping->MapViewOfFile,这只是一个举例不一定贴切。文件装载到内存中,装载器会按照PE文件的节区将文件装载映射到内存中。
而私有部分应该是进程在运行过程中动态申请的内存,比如VirtualAllocEx之类的函数,这部分是申请单堆空间,而这部分是进程动态申请的,没有文件与之对应。