<?xml version="1.0" encoding="utf-8"?><feed xmlns="http://www.w3.org/2005/Atom"><title type="text">博客园_高级DotNet调试 (Advanced .NET Debugging)</title><subtitle type="text">用强大的调试器来解决 .NET 问题</subtitle><id>http://feed.cnblogs.com/blog/u/33242/rss</id><updated>2011-02-11T14:18:30Z</updated><author><name>softfair</name><uri>http://www.cnblogs.com/softfair/</uri></author><generator>CNBlogs BlogServer</generator><link rel="alternate" type="text/html" href="http://www.cnblogs.com/softfair/"/><link rel="self" type="application/atom+xml" href="http://feed.cnblogs.com/blog/u/33242/rss"/><entry><id>http://www.cnblogs.com/softfair/archive/2011/02/11/1951697.html</id><title type="text">Windows中内存管理的一些知识</title><summary type="text">让我们来了解一下Windows中内存管理的一些知识:1.机器的物理内存由两部分组成。一部分为机器的主存RAM，也就是我们内存条的大小；另一部分为虚拟内存，它就在机器的硬盘上，以页文件的形式存在。2.每个进程都有自己的虚拟地址空间，对于具有32位寻址能力的机器来说，这个虚拟空间的大小为4GB。现在我们使用的机器就是4GB。3.进程的4GB虚拟地址空间又可以分成几个部分，其中进程真正私有的空间少于2GB（这段地址空间被称作&amp;amp;#8220;用户方式分区&amp;amp;#8221;），其余的2GB多空间都是给操作系统的，且这部分空间被所有的进程共享。（参考Windows核心编程Chapter 13）4</summary><published>2011-02-11T14:19:00Z</published><updated>2011-02-11T14:19:00Z</updated><author><name>softfair</name><uri>http://www.cnblogs.com/softfair/</uri></author><link rel="alternate" href="http://www.cnblogs.com/softfair/archive/2011/02/11/1951697.html"/><link rel="alternate" type="text/html" href="http://www.cnblogs.com/softfair/archive/2011/02/11/1951697.html"/><content type="html">&lt;p&gt;&lt;span style="widows: 2; text-transform: none; text-indent: 0px; border-collapse: separate; font: medium 'Times New Roman'; white-space: normal; orphans: 2; letter-spacing: normal; color: rgb(0,0,0); word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px" &gt;&lt;span style="text-align: left; line-height: 21px; font-family: verdana, sans-serif; font-size: 14px" &gt; &lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;让我们来了解一下&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Windows&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;中内存管理的一些知识&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;:&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;1.&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;机器的物理内存由两部分组成。一部分为机器的主存&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;RAM&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;，也就是我们内存条的大小；另一部分为虚拟内存，它就在机器的硬盘上，以页文件的形式存在。&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;2.&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;每个进程都有自己的虚拟地址空间，对于具有&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;32&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;位寻址能力的机器来说，这个虚拟空间的大小为&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;4GB&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;。现在我们使用的机器就是&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;4GB&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;。&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;3.&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;font color="#000000"&gt;&lt;span style="line-height: 24px; background-color: rgb(217,217,217); font-family: 宋体; font-size: 12pt; background-origin: initial; background-clip: initial"&gt;进程的&lt;/span&gt;&lt;span style="line-height: 24px; background-color: rgb(217,217,217); font-family: 宋体; font-size: 12pt; background-origin: initial; background-clip: initial" lang="EN-US"&gt;4GB&lt;/span&gt;&lt;span style="line-height: 24px; background-color: rgb(217,217,217); font-family: 宋体; font-size: 12pt; background-origin: initial; background-clip: initial"&gt;虚拟地址空间又可以分成几个部分，其中进程真正私有的空间少于&lt;/span&gt;&lt;span style="line-height: 24px; background-color: rgb(217,217,217); font-family: 宋体; font-size: 12pt; background-origin: initial; background-clip: initial" lang="EN-US"&gt;2GB&lt;/span&gt;&lt;span style="line-height: 24px; background-color: rgb(217,217,217); font-family: 宋体; font-size: 12pt; background-origin: initial; background-clip: initial"&gt;（这段地址空间被称作&amp;#8220;用户方式分区&amp;#8221;），其余的&lt;/span&gt;&lt;span style="line-height: 24px; background-color: rgb(217,217,217); font-family: 宋体; font-size: 12pt; background-origin: initial; background-clip: initial" lang="EN-US"&gt;2GB&lt;/span&gt;&lt;span style="line-height: 24px; background-color: rgb(217,217,217); font-family: 宋体; font-size: 12pt; background-origin: initial; background-clip: initial"&gt;多空间都是给操作系统的，且这部分空间被所有的进程共享。&lt;/span&gt;&lt;/font&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;（参考&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Windows&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;核心编程&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Chapter 13&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;）&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;4.&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; background-color: yellow; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt; background-origin: initial; background-clip: initial"&gt;为进程&amp;#8220;分配内存&amp;#8221;，这个概念可以细化：&amp;#8220;保留一段地址空间&amp;#8221;，&amp;#8220;提交一段内存空间&amp;#8221;，&amp;#8220;将内存空间映射到主存&amp;#8221;。在程序中我们通常所访问的地址都必须是进程地址空间中被保留和提交的那段地址空间。&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;4.1&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;保留一段地址空间&amp;#8221;：即从进程的&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;4GB&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;地址空间中保留一段地址空间，这个过程通过&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;VirtualAlloc&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;函数完成，并把分配类型参数设置为&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;MEM_RESERVE&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;。这段空间的起始地址必须是系统分配粒度的整数倍，大小必须是系统页面大小的整数倍。&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;4.2&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;提交一段内存空间&amp;#8221;：即为进程已保留的地址空间映射机器的物理内存，这里要特别注意，&lt;span style="line-height: 24px; background-color: red; background-origin: initial; background-clip: initial"&gt;所谓物理内存一般并不是机器的主存，而只是机器的虚拟内存&lt;/span&gt;。这个过程同样又&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;VirtualAlloc&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;完成，只是把分配类型参数设置为&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;MEM_COMMIT&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;。这段空间的起始地址和大小都必须是页面大小的整数倍。这样进程的对应被提交的区域就被映射到机器的虚拟内存上。&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;4.3&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; background-color: yellow; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt; background-origin: initial; background-clip: initial"&gt;&amp;#8220;将内存空间映射到主存&amp;#8221;：这点很重要，操作系统总是只有在进程提交的页面被访问时才将相应的页面加载到主存中，同时修改进程对应页面的地址空间映射。这时，进程的地址空间中的对应区域才和机器上的主存对应起来。&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&amp;nbsp;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Virtual Size&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;：&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;span style="line-height: 24px"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;该指标记录了当前进程申请成功的其虚拟地址空间的总的空间大小，包括&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;DLL/EXE&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;占用的地址和通过&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;VirtualAlloc API Reserve&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;的&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Memory Space&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;数量。请注意，该指标包括保留的地址空间。&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&amp;nbsp;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Private Bytes&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;：&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;span style="line-height: 24px"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;该指标记录了进程用户方式分区地址空间中已提交的总的空间大小。无论是直接调用&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;API&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;申请的内存，被&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Heap Manager&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;申请的内存，或者是&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;CLR&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;的&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;managed heap&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;，都算在里面。&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&amp;nbsp;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Working Set&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;：&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;span style="line-height: 24px"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;该指标记录了所有映射到进程虚拟地址空间的机器主存的大小，它不仅仅是用户方式分区部分的映射，而是整个进程地址空间的映射。即它同时包括内核方式分区中映射到机器主存的部分。由&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;4.3&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;可知，在用户方式分区部分只有在进程提交的页面被访问时才将相应的页面加载到主存中。而对于该部分的大小总是系统页面大小的整数倍。&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;span style="line-height: 24px"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;这里有一个问题，随着进程的不断运行，进程被访问的页面将可能不断增加，这是否意味着&amp;#8220;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Working Set&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8221;的大小会不断的累加呢？显然不是。在程序运行过程中影响&amp;#8220;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Working Set&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8221;的因素包括：&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;(1)&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;机器可用主存的大小&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;span &gt;&amp;nbsp;&lt;/span&gt;(2)&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;进程本身&amp;#8220;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Working Set&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8221;的大小范围。当机器的可用主存小于一定值时，系统会释放一些老的最近没有被访问的页面，把这些页面通过交换文件交换到机器的虚拟内存中；当&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Working Set&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;的大小大于该进程所设置的最大值时，同样会把一些老的页面交换到机器的虚拟内存中。当这些页面下次再被访问时，它们才加载到主存。&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;span style="line-height: 24px"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; background-color: yellow; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt; background-origin: initial; background-clip: initial"&gt;由上可知，&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; background-color: yellow; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt; background-origin: initial; background-clip: initial" lang="EN-US"&gt;Working Set&lt;/span&gt;&lt;span style="line-height: 24px; background-color: yellow; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt; background-origin: initial; background-clip: initial"&gt;&amp;#8220;一定比&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; background-color: yellow; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt; background-origin: initial; background-clip: initial" lang="EN-US"&gt;Private Bytes&lt;/span&gt;&lt;span style="line-height: 24px; background-color: yellow; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt; background-origin: initial; background-clip: initial"&gt;&amp;#8220;小，因为它只是&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; background-color: yellow; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt; background-origin: initial; background-clip: initial" lang="EN-US"&gt;Private Bytes&lt;/span&gt;&lt;span style="line-height: 24px; background-color: yellow; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt; background-origin: initial; background-clip: initial"&gt;&amp;#8220;对应的地址空间中被加载到主存的那部分。&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&amp;nbsp;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Page Faults&amp;#8221;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;span style="line-height: 24px"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;该指标和&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Working Set&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;密切相关，当进程访问某个页面，而这个页面却不在主存中时，就要发生一次&amp;#8220;&lt;/span&gt;&lt;span style="line-height: 24px; background-color: red; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt; background-origin: initial; background-clip: initial" lang="EN-US"&gt;Page Fault&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;，即进程访问非&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Working Set&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;中的页面时，发生一次&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Page Fault&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;，同时系统将对应页面加载到主存中。&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&amp;nbsp;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;span style="line-height: 24px"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;接下来的三个指标是对&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Working Set&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;的细化：&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;WS Private&amp;#8220;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;span style="line-height: 24px"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;该指标记录了进程&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Working Set&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;中被该进程所独享的空间大小。&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;"WS Shareable"&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;span style="line-height: 24px"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;该指标记录了进程&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Working Set&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;中能与别的进程共享的空间大小&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&amp;nbsp;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;WS Shared&amp;#8220;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;span style="line-height: 24px"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;该指标记录了进程&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Working Set&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;中已经与别的进程共享的空间大小&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;WS Shareable&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;和&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;WS Shared&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;两个指标乍一看令人感到疑惑，因为既然&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Working Set&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;属于&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Private Bytes&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;中的一部分，而&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Private Bytes&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;是进程私有的，为什么会有&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;WS Shareable&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;和&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;WS Shared&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;这两项呢？&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;span style="line-height: 24px"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt"&gt;认真一想，其实很容易理解，比如两个进程都需要同一个&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt" lang="EN-US"&gt;DLL&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt"&gt;的支持，所以在进程运行过程中，这个&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt" lang="EN-US"&gt;DLL&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt"&gt;被映射到了两个进程的地址空间中，如果这个&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt" lang="EN-US"&gt;DLL&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt"&gt;的大小为&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt" lang="EN-US"&gt;4K&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt"&gt;，在两个进程中都要提交&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt" lang="EN-US"&gt;4K&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt"&gt;的虚拟地址空间来映射这个&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt" lang="EN-US"&gt;DLL&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt"&gt;。当第一个进程访问了这个&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt" lang="EN-US"&gt;DLL&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt"&gt;时，这个&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt" lang="EN-US"&gt;DLL&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt"&gt;被加载到机器主存中，这时，第二个进程也要访问该&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt" lang="EN-US"&gt;DLL&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt"&gt;，这时，系统就不会再加载一遍该&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt" lang="EN-US"&gt;DLL&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt"&gt;了，因为这个&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt" lang="EN-US"&gt;DLL&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt"&gt;已经在主存中了。当然上面所说的访问仅仅是读取的操作，如果这时候某个进程要修改&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt" lang="EN-US"&gt;DLL&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt"&gt;对应这段地址中的某个单元时，这时，系统必须为第二个进程分配另外的新页面，并把要修改位置对应的页面拷贝的这个新页面，同时，第二个进程中的这个&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt" lang="EN-US"&gt;DLL&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt"&gt;被映射到这个新页面上。&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt" lang="EN-US"&gt;&lt;span style="line-height: 24px"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt"&gt;上面的分析中，&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt" lang="EN-US"&gt;DLL&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt"&gt;对应的&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt" lang="EN-US"&gt;4K&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt"&gt;的内存在第一个进程中便是&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt" lang="EN-US"&gt;WS Shareable&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt"&gt;&amp;#8220;。另外，内核方式分区中的所有代码都是被所有进程共享的，只要一个进程访问了这些页面，则在所有的进程的&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt" lang="EN-US"&gt;Working Set&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt"&gt;&amp;#8220;中都能体现。&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&amp;nbsp;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;三、下面我们来讨论一下这些内存指标与进程内存消耗之间的关系&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;span style="line-height: 24px"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;在计算机更新换代不断加速的今天，我们往往很少关注程序对内存的消耗，除非程序的内存消耗超出了我们的忍受范围&amp;#8212;&amp;#8212;大量的泄漏、运行速度下降等。&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;span style="line-height: 24px"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;那么，当我们在测进程的内存使用量时，到底应该使用哪个指标能更好的反应程序的内存消耗呢？&lt;span style="line-height: 24px; background-color: yellow; background-origin: initial; background-clip: initial"&gt;由于&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; background-color: yellow; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt; background-origin: initial; background-clip: initial" lang="EN-US"&gt;Windows&lt;/span&gt;&lt;span style="line-height: 24px; background-color: yellow; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt; background-origin: initial; background-clip: initial"&gt;自带的&lt;/span&gt;&lt;span style="line-height: 24px; background-color: yellow; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt; background-origin: initial; background-clip: initial" lang="EN-US"&gt;Task Manager&lt;/span&gt;&lt;span style="line-height: 24px; background-color: yellow; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt; background-origin: initial; background-clip: initial"&gt;中的&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; background-color: yellow; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt; background-origin: initial; background-clip: initial" lang="EN-US"&gt;Memory Usage&lt;/span&gt;&lt;span style="line-height: 24px; background-color: yellow; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt; background-origin: initial; background-clip: initial"&gt;&amp;#8220;所对应的指标就是&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; background-color: yellow; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt; background-origin: initial; background-clip: initial" lang="EN-US"&gt;Working Set&lt;/span&gt;&lt;span style="line-height: 24px; background-color: yellow; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt; background-origin: initial; background-clip: initial"&gt;&amp;#8220;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;，所以大部分人认为该指标能够很好的反应进程的内存使用量。&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;在得出结论之前，让我们来分析一下以上的这些指标：&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;就从&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Working Set&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;开始吧。&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Working Set&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;：&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;span style="line-height: 24px"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;进程中被加载到机器主存的所有页面大小的和。它可细分为&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;WS Shareable&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;和&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;WS Shared&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;。进程访问页面不再&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Working Set&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;中时，会发生一次&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Page Fault&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;且同时发生一次主存与虚拟内存之间的数据交换。综上所述，我们可以得出结论：&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;(a)&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Working Set&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;不是进程内存消耗的全部；&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;(b)&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;所有进程&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Working Set&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;的和也不等有机器主存总的消耗量，因为存在&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Working Shareable&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;与别的进程共享；&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;(c)&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Working Set&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;太大会影响机器的运行速度，因为&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Working Set&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;太大会导致机器的可用主存太少，从而导致将进程的老页面释放到虚拟内存，同时，进程&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Working Set&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;中的页面减少后，使进程发生&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Page Fault&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;的频率更高。因为在主存与虚拟内存之间交换数据需要时间，所以机器的运行速度要减慢。&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;(d)&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Working Set&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;由于数据交换的存在，该指标是动态的，在测量的过程中会不断变化。（变化的最小单位为&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;4K&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;）&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;span style="line-height: 24px"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px"&gt;&amp;nbsp;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;所以&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Working Set&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;指标强调的是进程对机器主存的消耗，不是进程内存的全部信息。&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;"Private Bytes"&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;span style="line-height: 24px"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; background-color: yellow; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt; background-origin: initial; background-clip: initial"&gt;该指标包含所有为进程提交的内存，包括机器主存和虚拟内存，可以认为它是进程对物理内存消耗，且该指标相对来说更加稳定。在程序产生内存泄漏时，该值一定是不断上涨的。&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;span style="line-height: 24px"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;综上所述，个人更倾向于使用&amp;#8221;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Private Bytes&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&amp;#8220;来定量进程的内存消耗和分析进程的内存泄漏。&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; background-color: yellow; color: black; font-size: 12pt; background-origin: initial; background-clip: initial" lang="EN-US"&gt;&amp;nbsp;&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; background-color: yellow; font-family: 宋体; color: black; font-size: 12pt; background-origin: initial; background-clip: initial"&gt;虚拟存储器是一个抽象概念，它为每一个进程提供了一个假象，好像每个进程都在独占的使用主存。每个进程看到的存储器都是一致的，称之为虚拟地址空间。&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: black; font-size: 12pt"&gt;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;每个进程看到得虚拟地址空间有大量准确定义的区（&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;area&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;）构成，每个区都有专门的功能。&lt;span style="line-height: 24px; background-color: red; background-origin: initial; background-clip: initial"&gt;从最低的地址看起&lt;/span&gt;：&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; line-height: 15pt; text-indent: -18pt; margin: 0cm 15pt 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 19px; font-family: Symbol; color: rgb(51,51,51); font-size: 10pt" lang="EN-US"&gt;&lt;span style="line-height: 19px"&gt;&amp;#183;&lt;span style="font: 7pt 'Times New Roman'"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;程序代码和数据：代码是从同一固定地址开始，紧接着的是和&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;C&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;全局变量相对应的数据区。&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;（应该就是所谓的静态存储空间）&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;&lt;span style="line-height: 18px" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; line-height: 15pt; text-indent: -18pt; margin: 0cm 15pt 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 19px; font-family: Symbol; color: rgb(51,51,51); font-size: 10pt" lang="EN-US"&gt;&lt;span style="line-height: 19px"&gt;&amp;#183;&lt;span style="font: 7pt 'Times New Roman'"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;堆：代码和数据区后紧随着的是运行时堆。作为调用&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;malloc&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;和&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;free&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;这样的&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;C&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;标准库函数，&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;堆可以&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;在运行时动态的扩展和收缩。（应该就是所谓的动态存储区）&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;&lt;span style="line-height: 18px" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; line-height: 15pt; text-indent: -18pt; margin: 0cm 15pt 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 19px; font-family: Symbol; color: rgb(51,51,51); font-size: 10pt" lang="EN-US"&gt;&lt;span style="line-height: 19px"&gt;&amp;#183;&lt;span style="font: 7pt 'Times New Roman'"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;共享库：在地址空间的中间附近是一块用来存放像&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;C&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;标准库和数学库这样共享库的代码和数据的区域。（&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;C&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;标准库函数的指令，连接阶段把他们加入到编译后的程序）&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;&lt;span style="line-height: 18px" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; line-height: 15pt; text-indent: -18pt; margin: 0cm 15pt 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 19px; font-family: Symbol; color: rgb(51,51,51); font-size: 10pt" lang="EN-US"&gt;&lt;span style="line-height: 19px"&gt;&amp;#183;&lt;span style="font: 7pt 'Times New Roman'"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;栈&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;：位于用户虚拟地址空间顶部的是用户&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;栈&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;，编译器用它来实现函数调用。和&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;堆一样&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;每次我们从函数返回时，&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;栈&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;就会收缩。&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;&lt;span style="line-height: 18px" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; line-height: 15pt; text-indent: -18pt; margin: 0cm 15pt 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 19px; font-family: Symbol; color: rgb(51,51,51); font-size: 10pt" lang="EN-US"&gt;&lt;span style="line-height: 19px"&gt;&amp;#183;&lt;span style="font: 7pt 'Times New Roman'"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;内核虚拟存储器：内核是操作系统总是驻留在存储器中的部分。地址空间顶部的四&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;分之一&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;部分是为内核预留的。（系统函数？这里说的&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;UNIX&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;系统，不知道&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;windows&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;下是不是这样的？）&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;&lt;span style="line-height: 18px" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;div style="border-bottom: windowtext 2.25pt double; border-left: medium none; padding-bottom: 1pt; padding-left: 0cm; padding-right: 0cm; border-top: medium none; border-right: medium none; padding-top: 0cm"&gt;&#xD;
&lt;p style="border-bottom: medium none; text-align: left; border-left: medium none; padding-bottom: 0cm; margin: 0cm 0cm 0pt; padding-left: 0cm; padding-right: 0cm; border-top: medium none; border-right: medium none; padding-top: 0cm"  align="left"&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;今天大多数计算机的字长都是&lt;span style="line-height: 18px" lang="EN-US"&gt;32&lt;/span&gt;字节，这就限制了虚拟地址空间为&lt;span style="line-height: 18px" lang="EN-US"&gt;4&lt;/span&gt;千兆字节（&lt;span style="line-height: 18px" lang="EN-US"&gt;4GB&lt;/span&gt;）&lt;span style="line-height: 18px" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&lt;/div&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;引言&lt;span style="line-height: 18px" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;　　&lt;span style="line-height: 18px; background-color: yellow; background-origin: initial; background-clip: initial" lang="EN-US"&gt;Windows&lt;/span&gt;&lt;span style="line-height: 18px; background-color: yellow; background-origin: initial; background-clip: initial"&gt;的内存结构是深入理解&lt;span style="line-height: 18px" lang="EN-US"&gt;Windows&lt;/span&gt;操作系统如何运作的&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 18px; background-color: yellow; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt; background-origin: initial; background-clip: initial"&gt;最&lt;/span&gt;&lt;span style="line-height: 18px; background-color: yellow; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt; background-origin: initial; background-clip: initial"&gt;关键之所在，通过对内存结构的认识可清楚地了解诸如进程&lt;/span&gt;&lt;span style="line-height: 18px; background-color: yellow; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt; background-origin: initial; background-clip: initial"&gt;间数据&lt;/span&gt;&lt;span style="line-height: 18px; background-color: yellow; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt; background-origin: initial; background-clip: initial"&gt;的共享、对内存进行有效的管理等问题，从而能够在程序设计时使程序以更加有效的方式运行。&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;Windows&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;操作系统对内存的管理可采取多种不同的方式，其中虚拟内存的管理方式可用来管理大型的对象和结构数组。&lt;span style="line-height: 18px" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;　　在&lt;span style="line-height: 18px" lang="EN-US"&gt;Windows&lt;/span&gt;系统中，任何一个进程都被赋予其自己的虚拟地址空间，该虚拟地址空间覆盖了一个相当大的范围，对于&lt;span style="line-height: 18px" lang="EN-US"&gt;32&lt;/span&gt;位进程，其地址空间为&lt;span style="line-height: 18px" lang="EN-US"&gt;232=4,294,967,296 Byte&lt;/span&gt;，这使得一个指针可以使用从&lt;span style="line-height: 18px" lang="EN-US"&gt;0x00000000&lt;/span&gt;到&lt;span style="line-height: 18px" lang="EN-US"&gt;0xFFFFFFFF&lt;/span&gt;的&lt;span style="line-height: 18px" lang="EN-US"&gt;4GB&lt;/span&gt;范围之内的任何一个值。&lt;span style="line-height: 18px; background-color: yellow; background-origin: initial; background-clip: initial"&gt;虽然每一个&lt;span style="line-height: 18px" lang="EN-US"&gt;32&lt;/span&gt;位进程可使用&lt;span style="line-height: 18px" lang="EN-US"&gt;4GB&lt;/span&gt;的地址空间，但并不意味着每一个进程实际拥有&lt;span style="line-height: 18px" lang="EN-US"&gt;4GB&lt;/span&gt;的物理地址空间，该地址空间仅仅是一个虚拟地址空间，此虚拟地址空间只是内存地址的一个范围。进程实际可以得到的物理内存要远小于其虚拟地址空间。进程的虚拟地址空间是为每个进程所私有的，在进程内运行的线程对内存空间的访问都被限制在调用进程之内，而不能访问属于其他进程的内存空间。这样，在不同的进程中可以使用相同地址的指针来指向属于各自调用进程的内容而不会由此引起混乱。&lt;/span&gt;下面分别对虚拟内存的各具体技术进行介绍。&lt;span style="line-height: 18px" lang="EN-US"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;strong&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;地址空间中区域的保留与释放&lt;/span&gt;&lt;/strong&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;在进程创建&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;之初并被&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;赋予地址空间时，其虚拟地址空间尚未分配，处于空闲状态。这时地址空间内的内存是不能使用的，&lt;span style="line-height: 18px; background-color: yellow; background-origin: initial; background-clip: initial"&gt;必须首先通过&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 18px; background-color: yellow; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt; background-origin: initial; background-clip: initial" lang="EN-US"&gt;VirtualAlloc&lt;/span&gt;&lt;span style="line-height: 18px; background-color: yellow; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt; background-origin: initial; background-clip: initial"&gt;（）函数来分配其内的各个区域，对其进行保留&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;。&lt;span style="line-height: 18px" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;LPVOID&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;VirtualAlloc&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;(&lt;br /&gt;&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;　&lt;span style="line-height: 18px" lang="EN-US"&gt;LPVOID&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;lpAddress&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;,&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;　&lt;span style="line-height: 18px" lang="EN-US"&gt;DWORD&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;dwSize&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;,&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;　&lt;span style="line-height: 18px" lang="EN-US"&gt;DWORD&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;flAllocationType&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;,&lt;br /&gt;&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;　&lt;span style="line-height: 18px" lang="EN-US"&gt;DWORD&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;flProtect&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;&lt;br /&gt;);&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 12pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;其参数&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;lpAddress&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;包含一个内存地址，用于定义待分配区域的首地址。通常可将此参数设置为&lt;span style="line-height: 18px" lang="EN-US"&gt;NULL&lt;/span&gt;，由系统通过搜索地址空间来决定满足条件的未保留地址空间。这时系统可从地址空间的任意位置处开始保留一个区域，而且还可以通过向参数&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;flAllocationType&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;设置&lt;span style="line-height: 18px" lang="EN-US"&gt;MEM_TOP_DOWN&lt;/span&gt;标志来指明在尽可能高的地址上分配内存。如果不希望由系统自动完成对内存区域的分配而为&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;lpAddress&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;设定了内存地址（&lt;span style="line-height: 18px; background-color: yellow; background-origin: initial; background-clip: initial"&gt;必须确保其始终位于进程的用户模式分区中，否则将会导致分配的失败&lt;/span&gt;），那么系统将在进行分配之前首先检查在该内存地址上是否存在足够大的未保留空间，如果存在一个足够大的空闲区域，那么系统将会保留此区域并返回此保留区域的虚拟地址，否则将导致分配的失败而返回&lt;span style="line-height: 18px" lang="EN-US"&gt;NULL&lt;/span&gt;。这里需要特别指出的是，在指定&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;lpAddress&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;的内存地址时，必须确保是从一个分配粒度的边界处开始。&lt;span style="line-height: 18px" lang="EN-US"&gt;&lt;br /&gt;&lt;/span&gt;一般来说，在不同的&lt;span style="line-height: 18px" lang="EN-US"&gt;CPU&lt;/span&gt;平台下分配粒度各不相同，&lt;span style="line-height: 18px; background-color: yellow; background-origin: initial; background-clip: initial"&gt;但目前所有&lt;span style="line-height: 18px" lang="EN-US"&gt;Windows&lt;/span&gt;环境下的&lt;span style="line-height: 18px" lang="EN-US"&gt;CPU&lt;/span&gt;如&lt;span style="line-height: 18px" lang="EN-US"&gt;x86&lt;/span&gt;、&lt;span style="line-height: 18px" lang="EN-US"&gt;32&lt;/span&gt;位&lt;span style="line-height: 18px" lang="EN-US"&gt;Alpha&lt;/span&gt;、&lt;span style="line-height: 18px" lang="EN-US"&gt;64&lt;/span&gt;位&lt;span style="line-height: 18px" lang="EN-US"&gt;Alpha&lt;/span&gt;以及&lt;span style="line-height: 18px" lang="EN-US"&gt;IA-64&lt;/span&gt;等均是采用&lt;span style="line-height: 18px" lang="EN-US"&gt;64KB&lt;/span&gt;的分配粒度。&lt;/span&gt;如果保留区域的起始地址没有遵循从&lt;span style="line-height: 18px" lang="EN-US"&gt;64KB&lt;/span&gt;分配粒度的边界开始之一原则，系统将自动调整该地址到最接近的&lt;span style="line-height: 18px" lang="EN-US"&gt;64K&lt;/span&gt;的倍数。例如，如果指定的&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;lpAddress&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;为&lt;span style="line-height: 18px" lang="EN-US"&gt;0x00781022&lt;/span&gt;，那么此保留区域实际是从&lt;span style="line-height: 18px" lang="EN-US"&gt;0x00780000&lt;/span&gt;开始分配的。参数&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;dwSize&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;指定了保留区域的大小。但是系统实际保留的区域大小必须是&lt;span style="line-height: 18px" lang="EN-US"&gt;CPU&lt;/span&gt;页面大小的整数&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;倍&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;，如果指定的&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;dwSize&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;并非&lt;span style="line-height: 18px" lang="EN-US"&gt;CPU&lt;/span&gt;页面的整数&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;倍&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;，&lt;span style="line-height: 18px; background-color: yellow; background-origin: initial; background-clip: initial"&gt;系统将自动对其进行调整，使其达到与之最接近的页面大小整数&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 18px; background-color: yellow; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt; background-origin: initial; background-clip: initial"&gt;倍&lt;/span&gt;&lt;span style="line-height: 18px; background-color: yellow; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt; background-origin: initial; background-clip: initial"&gt;。&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;与分配粒度一样，对于不同的&lt;span style="line-height: 18px" lang="EN-US"&gt;CPU&lt;/span&gt;平台其页面大小也是不一样的。在&lt;span style="line-height: 18px" lang="EN-US"&gt;x86&lt;/span&gt;平台下，页面大小为&lt;span style="line-height: 18px" lang="EN-US"&gt;4KB&lt;/span&gt;，在&lt;span style="line-height: 18px" lang="EN-US"&gt;32&lt;/span&gt;位&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;Alpah&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;平台下，页面大小为&lt;span style="line-height: 18px" lang="EN-US"&gt;8KB&lt;/span&gt;。在使用时可以通过&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;GetSystemInfo&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;（）来决定当前主机的页面大小。参数&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;flAllocationType&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;和&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;flProtect&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;分别定义了分配类型和访问保护属性。由于&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;VirtualAlloc&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;（）可用来保留一个区域也可以用来占用物理存储器，因此通过&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;flAllocationType&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;来指定当前是要保留一个区域还是要占用物理存储器。其可能使用的内存分配类型有：&lt;span style="line-height: 18px" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="padding-bottom: 0px; margin: 1em 0px 0.5em; padding-left: 0px; padding-right: 0px; padding-top: 0px"&gt;&lt;/p&gt;&#xD;
&lt;p&gt;&lt;table style="width: 1011px"  border="1" cellspacing="0" cellpadding="0" width="100%"&gt;&#xD;
&lt;tbody&gt;&#xD;
&lt;tr&gt;&#xD;
&lt;td style="border-bottom-color: rgb(236,233,216); padding-bottom: 0.75pt; background-color: transparent; border-top-color: rgb(236,233,216); padding-left: 0.75pt; padding-right: 0.75pt; border-right-color: rgb(236,233,216); border-left-color: rgb(236,233,216); padding-top: 0.75pt"&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;分配类型&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;&lt;span style="line-height: 24px" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&lt;/td&gt;&#xD;
&lt;td style="border-bottom-color: rgb(236,233,216); padding-bottom: 0.75pt; background-color: transparent; border-top-color: rgb(236,233,216); padding-left: 0.75pt; padding-right: 0.75pt; border-right-color: rgb(236,233,216); border-left-color: rgb(236,233,216); padding-top: 0.75pt"&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;类型说明&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&#xD;
&lt;tr&gt;&#xD;
&lt;td style="border-bottom-color: rgb(236,233,216); padding-bottom: 0.75pt; background-color: transparent; border-top-color: rgb(236,233,216); padding-left: 0.75pt; padding-right: 0.75pt; border-right-color: rgb(236,233,216); border-left-color: rgb(236,233,216); padding-top: 0.75pt"&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;MEM_COMMIT&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;/td&gt;&#xD;
&lt;td style="border-bottom-color: rgb(236,233,216); padding-bottom: 0.75pt; background-color: transparent; border-top-color: rgb(236,233,216); padding-left: 0.75pt; padding-right: 0.75pt; border-right-color: rgb(236,233,216); border-left-color: rgb(236,233,216); padding-top: 0.75pt"&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; background-color: yellow; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt; background-origin: initial; background-clip: initial"&gt;为特定的页面区域分配内存中或磁盘的页面文件中的物理存储&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&#xD;
&lt;tr&gt;&#xD;
&lt;td style="border-bottom-color: rgb(236,233,216); padding-bottom: 0.75pt; background-color: transparent; border-top-color: rgb(236,233,216); padding-left: 0.75pt; padding-right: 0.75pt; border-right-color: rgb(236,233,216); border-left-color: rgb(236,233,216); padding-top: 0.75pt"&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;MEM_PHYSICAL&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;/td&gt;&#xD;
&lt;td style="border-bottom-color: rgb(236,233,216); padding-bottom: 0.75pt; background-color: transparent; border-top-color: rgb(236,233,216); padding-left: 0.75pt; padding-right: 0.75pt; border-right-color: rgb(236,233,216); border-left-color: rgb(236,233,216); padding-top: 0.75pt"&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;分配物理内存（仅用于地址窗口扩展内存）&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&#xD;
&lt;tr&gt;&#xD;
&lt;td style="border-bottom-color: rgb(236,233,216); padding-bottom: 0.75pt; background-color: transparent; border-top-color: rgb(236,233,216); padding-left: 0.75pt; padding-right: 0.75pt; border-right-color: rgb(236,233,216); border-left-color: rgb(236,233,216); padding-top: 0.75pt"&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;MEM_RESERVE&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;/td&gt;&#xD;
&lt;td style="border-bottom-color: rgb(236,233,216); padding-bottom: 0.75pt; background-color: transparent; border-top-color: rgb(236,233,216); padding-left: 0.75pt; padding-right: 0.75pt; border-right-color: rgb(236,233,216); border-left-color: rgb(236,233,216); padding-top: 0.75pt"&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;保留进程的虚拟地址空间，而不分配任何物理存储。保留页面可通过继续调用&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;VirtualAlloc&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;（）而被占用&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&#xD;
&lt;tr&gt;&#xD;
&lt;td style="border-bottom-color: rgb(236,233,216); padding-bottom: 0.75pt; background-color: transparent; border-top-color: rgb(236,233,216); padding-left: 0.75pt; padding-right: 0.75pt; border-right-color: rgb(236,233,216); border-left-color: rgb(236,233,216); padding-top: 0.75pt"&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;MEM_RESET&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;/td&gt;&#xD;
&lt;td style="border-bottom-color: rgb(236,233,216); padding-bottom: 0.75pt; background-color: transparent; border-top-color: rgb(236,233,216); padding-left: 0.75pt; padding-right: 0.75pt; border-right-color: rgb(236,233,216); border-left-color: rgb(236,233,216); padding-top: 0.75pt"&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;指明在内存中由参数&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;lpAddress&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;和&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;dwSize&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;指定的数据无效&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&#xD;
&lt;tr&gt;&#xD;
&lt;td style="border-bottom-color: rgb(236,233,216); padding-bottom: 0.75pt; background-color: transparent; border-top-color: rgb(236,233,216); padding-left: 0.75pt; padding-right: 0.75pt; border-right-color: rgb(236,233,216); border-left-color: rgb(236,233,216); padding-top: 0.75pt"&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;MEM_TOP_DOWN&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;/td&gt;&#xD;
&lt;td style="border-bottom-color: rgb(236,233,216); padding-bottom: 0.75pt; background-color: transparent; border-top-color: rgb(236,233,216); padding-left: 0.75pt; padding-right: 0.75pt; border-right-color: rgb(236,233,216); border-left-color: rgb(236,233,216); padding-top: 0.75pt"&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;在尽可能高的地址上分配内存（&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Windows 98&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;忽略此标志）&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&#xD;
&lt;tr&gt;&#xD;
&lt;td style="border-bottom-color: rgb(236,233,216); padding-bottom: 0.75pt; background-color: transparent; border-top-color: rgb(236,233,216); padding-left: 0.75pt; padding-right: 0.75pt; border-right-color: rgb(236,233,216); border-left-color: rgb(236,233,216); padding-top: 0.75pt"&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;MEM_WRITE_WATCH&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;/td&gt;&#xD;
&lt;td style="border-bottom-color: rgb(236,233,216); padding-bottom: 0.75pt; background-color: transparent; border-top-color: rgb(236,233,216); padding-left: 0.75pt; padding-right: 0.75pt; border-right-color: rgb(236,233,216); border-left-color: rgb(236,233,216); padding-top: 0.75pt"&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;必须与&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;MEM_RESERVE&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;一起指定，使系统跟踪那些被写入分配区域的页面（仅针对&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;Windows 98&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;）&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/p&gt;&#xD;
&lt;p style="padding-bottom: 0px; margin: 1em 0px 0.5em; padding-left: 0px; padding-right: 0px; padding-top: 0px"&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 12pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;　　分配成功完成后，即在进程的虚拟地址空间中保留了一个区域，可以对此区域中的内存进行保护权限许可范围内的访问。当不再需要&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;访问此&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;地址空间区域时，应释放此区域。由&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;VirtualFree&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;（）负责完成。其函数原型为：&lt;span style="line-height: 18px" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="padding-bottom: 0px; margin: 1em 0px 0.5em; padding-left: 0px; padding-right: 0px; padding-top: 0px"&gt;&lt;/p&gt;&#xD;
&lt;p&gt;&lt;table style="background-color: white; width: 1013px; background-origin: initial; background-clip: initial"  border="0" cellpadding="0" width="100%"&gt;&#xD;
&lt;tbody&gt;&#xD;
&lt;tr&gt;&#xD;
&lt;td style="border-bottom-color: rgb(236,233,216); padding-bottom: 0.75pt; background-color: transparent; border-top-color: rgb(236,233,216); padding-left: 0.75pt; padding-right: 0.75pt; border-right-color: rgb(236,233,216); border-left-color: rgb(236,233,216); padding-top: 0.75pt"&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;BOOL VirtualFree(&lt;br /&gt;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;　&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;LPVOID lpAddress,&lt;br /&gt;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;　&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;DWORD dwSize,&lt;br /&gt;&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt"&gt;　&lt;/span&gt;&lt;span style="line-height: 24px; font-family: 宋体; color: rgb(51,51,51); font-size: 12pt" lang="EN-US"&gt;DWORD dwFreeType&lt;br /&gt;);&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/p&gt;&#xD;
&lt;p style="padding-bottom: 0px; margin: 1em 0px 0.5em; padding-left: 0px; padding-right: 0px; padding-top: 0px"&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;其中，参数&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;lpAddress&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;为指向待释放页面区域的指针。如果参数&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;dwFreeType&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;指定了&lt;span style="line-height: 18px" lang="EN-US"&gt;MEM_RELEASE&lt;/span&gt;，则&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;lpAddress&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;必须为页面区域被保留时由&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;VirtualAlloc&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;（）所返回的基地址。参数&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;dwSize&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;指定了要释放的地址空间区域的大小，如果参数&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;dwFreeType&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;指定了&lt;span style="line-height: 18px" lang="EN-US"&gt;MEM_RELEASE&lt;/span&gt;标志，则将&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;dwSize&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;设置为&lt;span style="line-height: 18px" lang="EN-US"&gt;0&lt;/span&gt;，由系统计算在特定内存地址上的待释放区域的大小。参数&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;dwFreeType&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;为所执行的释放操作的类型，其可能的取值为&lt;span style="line-height: 18px" lang="EN-US"&gt;MEM_RELEASE&lt;/span&gt;和&lt;span style="line-height: 18px" lang="EN-US"&gt;MEM_DECOMMIT&lt;/span&gt;，其中&lt;span style="line-height: 18px" lang="EN-US"&gt;MEM_RELEASE&lt;/span&gt;标志指明要释放指定的保留页面区域，&lt;span style="line-height: 18px" lang="EN-US"&gt;MEM_DECOMMIT&lt;/span&gt;标志则对指定的占用页面区域进行占用的解除。如果&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;VirtualFree&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;（）成功执行完成，将回收全部范围的已分配页面，此后如再对这些已释放页面区域内存的访问将引发内存访问异常。释放后的页面区域可供系统继续分配使用。&lt;span style="line-height: 18px" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;　　下面这段代码演示了由系统在进程的用户模式分区内保留一个&lt;span style="line-height: 18px" lang="EN-US"&gt;64KB&lt;/span&gt;大小的区域，并将其释放的过程：&lt;span style="line-height: 18px" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;//&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;在地址空间中保留一个区域&lt;span style="line-height: 18px" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;LPBYTE&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;bBuffer&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;&lt;span &gt;&amp;nbsp;&lt;/span&gt;= (LPBYTE&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;)VirtualAlloc&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;(NULL, 65536, MEM_RESERVE, PAGE_READWRITE);&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;&amp;#8230;&amp;#8230;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;//&lt;span &gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt"&gt;释放已保留的区域&lt;span style="line-height: 18px" lang="EN-US"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p style="text-align: left; padding-bottom: 0px; margin: 0cm 0cm 0pt; padding-left: 0px; padding-right: 0px; padding-top: 0px"  align="left"&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;VirtualFree(bBuffer&lt;/span&gt;&lt;span style="line-height: 18px; font-family: 宋体; color: rgb(51,51,51); font-size: 9pt" lang="EN-US"&gt;, 0, MEM_RELEASE);&lt;/span&gt;&lt;/p&gt;&#xD;
&lt;p&gt;&lt;/span&gt;&lt;/span&gt;&amp;nbsp;&lt;/p&gt;&lt;img src="http://www.cnblogs.com/softfair/aggbug/1951697.html?type=1" width="1" height="1" alt=""/&gt;&lt;p&gt;&lt;a href="http://www.cnblogs.com/softfair/archive/2011/02/11/1951697.html" target="_blank"&gt;本文链接&lt;/a&gt;&lt;/p&gt;</content></entry><entry><id>http://www.cnblogs.com/softfair/archive/2008/12/30/SSO-SAML-ws-fedreation-CAS-wh.html</id><title type="text">SSO(Single Sign-on) in Action</title><summary type="text">SSO(Single Sign-on) in Action1. SSO 原理浅谈  SSO 是一个非常大的主题，我对这个主题有着深深的感受，自从广州 UserGroup 的论坛成立以来，无数网友都在尝试使用开源的 CAS ， Kerberos 也提供另外一种方式的 SSO ，即基于 Windows 域的 SSO ，还有就是从 2005 年开始一直兴旺不衰的 SAML 。  如果将这些免费的 SSO...</summary><published>2008-12-30T08:14:00Z</published><updated>2008-12-30T08:14:00Z</updated><author><name>softfair</name><uri>http://www.cnblogs.com/softfair/</uri></author><link rel="alternate" href="http://www.cnblogs.com/softfair/archive/2008/12/30/SSO-SAML-ws-fedreation-CAS-wh.html"/><link rel="alternate" type="text/html" href="http://www.cnblogs.com/softfair/archive/2008/12/30/SSO-SAML-ws-fedreation-CAS-wh.html"/></entry><entry><id>http://www.cnblogs.com/softfair/archive/2008/12/14/1354994.html</id><title type="text">阿里巴巴将跌破1元股价</title><summary type="text">阿里巴巴将跌破1元股价</summary><published>2008-12-14T15:03:00Z</published><updated>2008-12-14T15:03:00Z</updated><author><name>softfair</name><uri>http://www.cnblogs.com/softfair/</uri></author><link rel="alternate" href="http://www.cnblogs.com/softfair/archive/2008/12/14/1354994.html"/><link rel="alternate" type="text/html" href="http://www.cnblogs.com/softfair/archive/2008/12/14/1354994.html"/></entry><entry><id>http://www.cnblogs.com/softfair/archive/2008/11/25/1340573.html</id><title type="text">你已经知道的，但你并不了解的世界--献给80年代出生的人们</title><summary type="text">你已经知道的，但你并不了解的世界--献给80年代出生的人们</summary><published>2008-11-25T05:11:00Z</published><updated>2008-11-25T05:11:00Z</updated><author><name>softfair</name><uri>http://www.cnblogs.com/softfair/</uri></author><link rel="alternate" href="http://www.cnblogs.com/softfair/archive/2008/11/25/1340573.html"/><link rel="alternate" type="text/html" href="http://www.cnblogs.com/softfair/archive/2008/11/25/1340573.html"/></entry><entry><id>http://www.cnblogs.com/softfair/archive/2008/11/15/1334266.html</id><title type="text">word 2007 中插入图片无法显示，只能显示底部一部分</title><summary type="text">故障现象向正在编辑的Word文档中插入一个图形时，发现插入的图形只显示出了一部分。下半部分，图片上面有文字，还能输入文字和回车。好像图片在文字下面一样，就露出了一个底部。无论怎样调整都不能解决问题，如果用浮于文字上方，那是可以的，但我现在需要的是嵌入式的版式。请问应如何处理？感觉是高度被限制了。&amp;lt;---------------------------------&amp;gt;分析处理出现此故障的原...</summary><published>2008-11-15T12:57:00Z</published><updated>2008-11-15T12:57:00Z</updated><author><name>softfair</name><uri>http://www.cnblogs.com/softfair/</uri></author><link rel="alternate" href="http://www.cnblogs.com/softfair/archive/2008/11/15/1334266.html"/><link rel="alternate" type="text/html" href="http://www.cnblogs.com/softfair/archive/2008/11/15/1334266.html"/></entry><entry><id>http://www.cnblogs.com/softfair/archive/2008/10/29/1321841.html</id><title type="text">国人、人性、茶道、中庸、道路</title><summary type="text">最近爱看《血色迷雾》，尤其喜欢那里面的经典话语一、关于国人为什么中华民族会遭受外来侵略，为什么30年代的上海会沦陷，剧中文康有一段话，将民族及国人的劣根性披露无余。文康道：我终于明白了，秦桧怎样以莫须有的罪名，谋害了爱国忠良岳飞铸成了千古奇冤。还有无辜的女子窦娥，面对地痞无赖的谋名胁婚，屈招领刑，终至天悲地恸，六月飞雪。我此次来梧桐，以君子始，以小人止，最终祸起萧墙。自己人先打得头破血流，我深深地...</summary><published>2008-10-29T01:45:00Z</published><updated>2008-10-29T01:45:00Z</updated><author><name>softfair</name><uri>http://www.cnblogs.com/softfair/</uri></author><link rel="alternate" href="http://www.cnblogs.com/softfair/archive/2008/10/29/1321841.html"/><link rel="alternate" type="text/html" href="http://www.cnblogs.com/softfair/archive/2008/10/29/1321841.html"/></entry><entry><id>http://www.cnblogs.com/softfair/archive/2008/10/08/1306247.html</id><title type="text">从“李约瑟难题”到“胡润问题”二</title><summary type="text">到这时，胡润和他的排行榜，已经构成了一个十分有趣的商业人文现象：对财富的追逐和关注，使排行榜倍受瞩目，而原始积累的灰色、排名的不科学乃至相当多人的仇富情结，则造成了观念及商业运作层面的混乱。以至于每次排行榜公布，便会有税务机构前去上榜富豪的公司查税，而往往又是一查一个准，那些因上榜而突然曝光的顶级富豪――尤其是排在前10位的则常常在传媒的追踪下突然显出不该有的&amp;#8220;尾巴&amp;#8221;来，如...</summary><published>2008-10-08T04:33:00Z</published><updated>2008-10-08T04:33:00Z</updated><author><name>softfair</name><uri>http://www.cnblogs.com/softfair/</uri></author><link rel="alternate" href="http://www.cnblogs.com/softfair/archive/2008/10/08/1306247.html"/><link rel="alternate" type="text/html" href="http://www.cnblogs.com/softfair/archive/2008/10/08/1306247.html"/></entry><entry><id>http://www.cnblogs.com/softfair/archive/2008/10/08/1306243.html</id><title type="text">从“李约瑟难题”到“胡润问题”一</title><summary type="text">1942年11月，李约瑟（Joseph Needham 1900-1995）从伦敦出发，过了四个月，才由昆明辗转抵达重庆。他是英国剑桥大学的生化学家，从1943年到1946年，李约瑟以“中英科学合作馆”馆长的身份，先后做了十一次的长途考察，路程长达3万里左右。就是在这个过程中，他提出了一个日后十分著名的“李约瑟难题”（Needham’s Grand Question）。</summary><published>2008-10-08T04:30:00Z</published><updated>2008-10-08T04:30:00Z</updated><author><name>softfair</name><uri>http://www.cnblogs.com/softfair/</uri></author><link rel="alternate" href="http://www.cnblogs.com/softfair/archive/2008/10/08/1306243.html"/><link rel="alternate" type="text/html" href="http://www.cnblogs.com/softfair/archive/2008/10/08/1306243.html"/></entry><entry><id>http://www.cnblogs.com/softfair/archive/2008/09/17/l-dynamic-libraries.html</id><title type="text">Linux 动态库剖析</title><summary type="text">动态链接的共享库是 GNU/Linux® 的一个重要方面。该种库允许可执行文件在运行时动态访问外部函数，从而（通过在需要时才会引入函数的方式）减少它们对内存的总体占用。本文研究了创建和使用静态库的过程，详细描述了开发它们的各种工具，并揭秘了这些库的工作方式。</summary><published>2008-09-17T02:27:00Z</published><updated>2008-09-17T02:27:00Z</updated><author><name>softfair</name><uri>http://www.cnblogs.com/softfair/</uri></author><link rel="alternate" href="http://www.cnblogs.com/softfair/archive/2008/09/17/l-dynamic-libraries.html"/><link rel="alternate" type="text/html" href="http://www.cnblogs.com/softfair/archive/2008/09/17/l-dynamic-libraries.html"/></entry><entry><id>http://www.cnblogs.com/softfair/archive/2008/08/25/1275618.html</id><title type="text"> 最近在做的项目，发两个图片,记录一笔，历次版本更新后可以查看。</title><summary type="text">最近在做的项目，发两个图片,记录一笔，历次版本更新后可以查看。再来一个：要低调一点。</summary><published>2008-08-25T03:17:00Z</published><updated>2008-08-25T03:17:00Z</updated><author><name>softfair</name><uri>http://www.cnblogs.com/softfair/</uri></author><link rel="alternate" href="http://www.cnblogs.com/softfair/archive/2008/08/25/1275618.html"/><link rel="alternate" type="text/html" href="http://www.cnblogs.com/softfair/archive/2008/08/25/1275618.html"/></entry></feed>
