<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/atom.xsl" media="screen"?><feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-US"><title type="html">Maarten&amp;#39;s blog</title><subtitle type="html" /><id>http://blogs.msdn.com/b/maartenb/atom.aspx</id><link rel="alternate" type="text/html" href="http://blogs.msdn.com/b/maartenb/" /><link rel="self" type="application/atom+xml" href="http://blogs.msdn.com/b/maartenb/atom.aspx" /><generator uri="http://telligent.com" version="5.6.50428.7875">Telligent Evolution Platform Developer Build (Build: 5.6.50428.7875)</generator><updated>2009-07-29T09:15:18Z</updated><entry><title>Debugging with VMWare</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/b/maartenb/archive/2011/02/03/debugging-with-vmware.aspx" /><id>http://blogs.msdn.com/b/maartenb/archive/2011/02/03/debugging-with-vmware.aspx</id><published>2011-02-03T16:52:54Z</published><updated>2011-02-03T16:52:54Z</updated><content type="html">&lt;p&gt;I normally use Windows Virtual PC for demos of Kernel debug scenarios. For a special occasion I needed to use VMWare. There are plenty of articles how to set it up and it is almost identical to Virtual PC. You basically connect over COM1 through a named pipe. But after hours of struggling I could not get it to work. 
&lt;/p&gt;&lt;p&gt;In the VM settings it says "Serial Port 2" which was somewhat weird already. Also in Device Manager on the VM it mentioned that the COM1 was already in use. Then I hit &lt;a href="http://driverentry.com.br/blog/?p=943"&gt;this article&lt;/a&gt;. Now I don't read Portuguese but the pictures are quite self-explanatory. Apparently when you have a printer connected to your machine, the first port is used by your printer. Adjusting the bcdedit settings fixed the problem. 
&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=10124420" width="1" height="1"&gt;</content><author><name>Maarten van de Bospoort MSFT</name><uri>http://blogs.msdn.com/maartenb/ProfileUrlRedirect.ashx</uri></author></entry><entry><title>ProcExp and XPerf tracing</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/b/maartenb/archive/2011/02/01/procexp-and-xperf-tracing.aspx" /><id>http://blogs.msdn.com/b/maartenb/archive/2011/02/01/procexp-and-xperf-tracing.aspx</id><published>2011-02-02T01:59:29Z</published><updated>2011-02-02T01:59:29Z</updated><content type="html">&lt;p&gt;I was trying to run some XPerf traces to prepare for a training, when it all of a sudden stopped working. The error I got was this:
&lt;/p&gt;&lt;p&gt;&lt;span style="font-family:Consolas"&gt;xperf: error: NT Kernel Logger: Cannot create a file when that file already exists. (0xb7).
&lt;/span&gt;&lt;/p&gt;&lt;p&gt;Weird because I ran the same command successfully multiple times before. Trying to stop a potentially conflicting session by using:
&lt;/p&gt;&lt;p&gt;&lt;span style="font-family:Consolas"&gt;Xperf –d blah.etl
&lt;/span&gt;&lt;/p&gt;&lt;p&gt;Failed with this error:
&lt;/p&gt;&lt;p&gt;&lt;span style="font-family:Consolas"&gt;xperf: error: Merge ETL: The specified path is invalid. (0xa1).
&lt;/span&gt;&lt;/p&gt;&lt;p&gt;And the event log contained this: 
&lt;/p&gt;&lt;p&gt;&lt;span style="font-family:Segoe UI; font-size:9pt"&gt;Session "NT Kernel Logger" failed to start with the following error: 0xC0000035
&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="font-family:Segoe UI; font-size:9pt"&gt;What has changed was that I had started ProcMon.exe. That uses the NT Kernel Logger. Exiting that process cleared the way for my first command. 
&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=10123434" width="1" height="1"&gt;</content><author><name>Maarten van de Bospoort MSFT</name><uri>http://blogs.msdn.com/maartenb/ProfileUrlRedirect.ashx</uri></author></entry><entry><title>NX dependency on PAE</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/b/maartenb/archive/2011/01/06/nx-dependency-on-pae.aspx" /><id>http://blogs.msdn.com/b/maartenb/archive/2011/01/06/nx-dependency-on-pae.aspx</id><published>2011-01-07T00:18:57Z</published><updated>2011-01-07T00:18:57Z</updated><content type="html">&lt;p&gt;Hardware supported NX is dependent on PAE (Windows Internals chapter 9. Memory). But why would that be? 
&lt;/p&gt;&lt;p&gt;The AMD64 Architecture Programmer's Manual (Volume 2: System Programming) mentions this:
&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;strong&gt;No Execute (NX) Bit. &lt;/strong&gt;Bit 63. This bit is present in the translation-table entries defined for PAE paging, with the exception that the legacy-mode PDPE does not contain this bit. This bit is not supported by non-PAE paging. 
&lt;/p&gt;&lt;p&gt;Again from Windows Internals we know that PTEs with PAE enabled are 64 bits long; without PAE they are only 32 bits long.  There simply is no bit 63 for non-PAE paging. We can see it in the debugger. 
&lt;/p&gt;&lt;p&gt;Here is a call stack from the non-PAE crash dump:
&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;0: kd&amp;gt; k
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;ChildEBP RetAddr  
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;8292dc0c 968a1160 nt!KeBugCheckEx+0x1e
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;8292dc3c 968a1768 i8042prt!I8xProcessCrashDump+0x251
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;8292dc88 82840d4d i8042prt!I8042KeyboardInterruptService+0x2ce
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;8292dc88 8286449a nt!KiInterruptDispatch+0x6d
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;8292dd24 00000000 nt!KiIdleLoop+0x1a
&lt;/span&gt;&lt;/p&gt;&lt;p&gt;
 &lt;/p&gt;&lt;p&gt;If we dump out the the ChildEBP for the 2&lt;sup&gt;nd&lt;/sup&gt; frame:
&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;0: kd&amp;gt; !pte 8292dc3c 
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;                 VA 8292dc3c
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;PDE at C0300828         PTE at C020A4B4
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;contains 001BF063       contains 0292D963
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;pfn 1bf   ---DA--KWEV   pfn 292d  -G-DA—KWEV
&lt;/span&gt;&lt;/p&gt;&lt;p&gt;
 &lt;/p&gt;&lt;p&gt;You see that the PTE contains a 32 bit value (0292D963). 
&lt;/p&gt;&lt;p&gt;The same exercise on a PAE enabled system gives us this call stack:
&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;1: kd&amp;gt; k
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;ChildEBP RetAddr  
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;807e1c0c 928bd160 nt!KeBugCheckEx+0x1e
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;807e1c3c 928bd768 i8042prt!I8xProcessCrashDump+0x251
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;807e1c88 828587cd i8042prt!I8042KeyboardInterruptService+0x2ce
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;807e1c88 8288101a nt!KiInterruptDispatch+0x6d
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;807e1d24 00000000 nt!KiIdleLoop+0x1a
&lt;/span&gt;&lt;/p&gt;&lt;p&gt;
 &lt;/p&gt;&lt;p&gt;The PTE here is 64 bit:
&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;1: kd&amp;gt; !pte 807e1c3c 
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;                    VA 807e1c3c
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;PDE at C0602018            PTE at C0403F08
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;contains 000000007A986863  contains &lt;strong&gt;800000002D21F963&lt;/strong&gt;
		&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;pfn 7a986     ---DA--KWEV   pfn 2d21f     -G-DA--KW-V
&lt;/span&gt;&lt;/p&gt;&lt;p&gt;
 &lt;/p&gt;&lt;p&gt;We would expect bit 63 on the ChildEBP to be set (EBP is on the stack and we would not want to execute any code from the stack: NX should be 1).
&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;1: kd&amp;gt; .formats 800000002D21F963
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;Evaluate expression:
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;  Hex:     80000000`2d21f963
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;  Decimal: -9223372036097574557
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;  Octal:   1000000000005510374543
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;  Binary:  &lt;strong&gt;1&lt;/strong&gt;0000000 00000000 00000000 00000000 00101101 00100001 11111001 01100011
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;…
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;
 &lt;/p&gt;&lt;p&gt;How about the return address of that same frame?
&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;1: kd&amp;gt; !pte 928bd768 
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;                    VA 928bd768
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;PDE at C06024A0            PTE at C04945E8
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;contains 0000000023615863  contains 000000007B9CD121
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;pfn 23615     ---DA--KWEV   pfn 7b9cd     -G--A—KREV
&lt;/span&gt;&lt;/p&gt;&lt;p&gt;
 &lt;/p&gt;&lt;p&gt;There the bit is not set:
&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;1: kd&amp;gt; .formats 000000007B9CD121
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;Evaluate expression:
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;  Hex:     7b9cd121
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;  Decimal: 2073874721
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;  Octal:   17347150441
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;  Binary:  01111011 10011100 11010001 00100001
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Consolas"&gt;…
&lt;/span&gt;&lt;/p&gt;&lt;p&gt;
 &lt;/p&gt;&lt;p&gt;Note that .formats truncates the preceding 0s.
&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=10112739" width="1" height="1"&gt;</content><author><name>Maarten van de Bospoort MSFT</name><uri>http://blogs.msdn.com/maartenb/ProfileUrlRedirect.ashx</uri></author></entry><entry><title>Install history in Reliability Monitor</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/b/maartenb/archive/2010/12/15/install-history-in-reliability-monitor.aspx" /><id>http://blogs.msdn.com/b/maartenb/archive/2010/12/15/install-history-in-reliability-monitor.aspx</id><published>2010-12-15T20:27:00Z</published><updated>2010-12-15T20:27:00Z</updated><content type="html">&lt;p&gt;Yesterday I was running into a problem with Visual Studio 2010 and SilverLight 4. I asked for help internally. There was some suspician that this history might have something&amp;nbsp;to do with my problem, but I had installed all kinds of tools on my machine over the last couple of weeks. Visual Studio 2008, 2010, Silverlight, Silverlight for Phone, etc. So I was grilled on when I installed what, and what order etc. I had no idea. &lt;/p&gt;
&lt;p&gt;So I ask my friend &lt;a href="http://blogs.msdn.com/patricka"&gt;Pat&lt;/a&gt;. He mentioned Reliability Monitor. So I type Windows key, "reliability", I select "View Reliability History"&amp;nbsp;and I got this:&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;img src="http://blogs.msdn.com/resized-image.ashx/__size/550x0/__key/CommunityServer-Blogs-Components-WeblogFiles/00-00-00-92-29/7701.relmon.jpg" border="0" /&gt;&lt;/p&gt;
&lt;p&gt;The nice thing is that it gives you a full history what went wrong, but also what is installed and when on the machine. You can even export an xml file and send it over or ask for it. This might come in handy when your mon/dad/aunt/neighbor claims that her/his machine magically became very sluggish without any user interaction. &lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=10105526" width="1" height="1"&gt;</content><author><name>Maarten van de Bospoort MSFT</name><uri>http://blogs.msdn.com/maartenb/ProfileUrlRedirect.ashx</uri></author><category term="windows installation history" scheme="http://blogs.msdn.com/b/maartenb/archive/tags/windows+installation+history/" /></entry><entry><title>Debugging Pool Leaks with X-Perf</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/b/maartenb/archive/2010/12/07/debugging-pool-leaks-with-x-perf.aspx" /><id>http://blogs.msdn.com/b/maartenb/archive/2010/12/07/debugging-pool-leaks-with-x-perf.aspx</id><published>2010-12-08T03:56:00Z</published><updated>2010-12-08T03:56:00Z</updated><content type="html">&lt;p&gt;The WDK has a tool called poolmon and you can use it to find leaks as is described in the Windows Internals book. You can use the NotMyFault demo app (&lt;a href="http://technet.microsoft.com/en-us/sysinternals/bb963901.aspx"&gt;here&lt;/a&gt;) to demo it. &lt;/p&gt;
&lt;p&gt;Instead of PoolMon you can also use WPT and X-Perf. Once installed, you run it like so:&lt;/p&gt;
&lt;p style="padding-left: 30px;"&gt;xperf -on diageasy+pool -stackwalk PoolAlloc&lt;/p&gt;
&lt;p&gt;Then you repro the leak. Once done you stop the trace with this:&lt;/p&gt;
&lt;p style="padding-left: 30px;"&gt;xperf -d leaker.etl. &lt;/p&gt;
&lt;p&gt;When you then open the trace in XPerfView, you will see four pool graphs in the fly-out:&lt;/p&gt;
&lt;p&gt;&lt;img src="http://blogs.msdn.com/resized-image.ashx/__size/550x0/__key/CommunityServer-Blogs-Components-WeblogFiles/00-00-00-92-29/6131.poolflyout.jpg" border="0" /&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;When you go to one of the graphs, you'll see a nice jagged line in there. Hovering the mouse over the graph will show the pool tag associated with the pool allocations. &lt;/p&gt;
&lt;p&gt;&lt;img src="http://blogs.msdn.com/resized-image.ashx/__size/550x0/__key/CommunityServer-Blogs-Components-WeblogFiles/00-00-00-92-29/5305.leakgraph.jpg" border="0" /&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;But there is more. When you select the jagged line in the graph, right-click and get the summary table you can actuall get the call stack. You have to rearrange the columns a bit. Pooltag first, then call stack will be good. Throw the type column to the right. Of course you need to have symbols loaded. But here is what you'll get:&lt;/p&gt;
&lt;p&gt;&lt;img src="http://blogs.msdn.com/resized-image.ashx/__size/550x0/__key/CommunityServer-Blogs-Components-WeblogFiles/00-00-00-92-29/4621.leakstack.jpg" border="0" /&gt;&lt;/p&gt;
&lt;p&gt;This is obviously a convoluted scenario with a large frequent leak from NotMyFault. Nevertheless, it is easy to get to the culprit. If you have symbols for myfault.sys available, then you would right there and then have the function and source line. &lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=10101794" width="1" height="1"&gt;</content><author><name>Maarten van de Bospoort MSFT</name><uri>http://blogs.msdn.com/maartenb/ProfileUrlRedirect.ashx</uri></author></entry><entry><title>Installing WPT (XPerf) from SDK</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/b/maartenb/archive/2010/11/17/installing-wpt-xperf-from-sdk.aspx" /><id>http://blogs.msdn.com/b/maartenb/archive/2010/11/17/installing-wpt-xperf-from-sdk.aspx</id><published>2010-11-17T15:50:00Z</published><updated>2010-11-17T15:50:00Z</updated><content type="html">&lt;p&gt;&lt;span style="font-size: small;"&gt;&lt;span style="font-family: arial,helvetica,sans-serif;"&gt;&lt;span style="font-size: x-small;"&gt;&lt;span style="color: #000000;"&gt;This week I got a couple of requests how to install WPT from the SDK. You need to jump through some hoops.&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="font-size: small;"&gt;&lt;span style="font-family: arial,helvetica,sans-serif;"&gt;&lt;span style="font-size: x-small;"&gt;&lt;span style="font-family: arial,helvetica,sans-serif;"&gt;&lt;span style="color: #000000;"&gt;If you bing "download xperf" you get &lt;a href="http://www.microsoft.com/downloads/en/details.aspx?FamilyID=c17ba869-9671-4330-a63e-1fd44e0e2505&amp;amp;displaylang=en"&gt;here&lt;/a&gt;. &lt;span style="mso-bidi-font-family: 'Times New Roman';"&gt;In there it says to install from the SDK:&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal"&gt;&lt;span style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt; mso-bidi-font-family: 'Times New Roman';"&gt;&lt;o:p&gt;&lt;span style="font-size: x-small;"&gt;&lt;span style="font-family: arial,helvetica,sans-serif;"&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;span style="font-size: x-small;"&gt;&lt;span style="font-family: arial,helvetica,sans-serif;"&gt;&lt;span style="line-height: 125%; color: #333333; mso-bidi-font-family: Symbol; mso-fareast-font-family: Symbol; mso-bidi-font-size: 9.5pt;"&gt;&lt;span style="mso-list: Ignore;"&gt;&amp;middot;&lt;span style="line-height: normal; font-variant: normal; font-style: normal; font-weight: normal;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="line-height: 125%; color: #333333;"&gt;&lt;a href="http://www.microsoft.com/downloads/details.aspx?FamilyID=c17ba869-9671-4330-a63e-1fd44e0e2505"&gt;&lt;span style="color: black; mso-bidi-font-family: 'Segoe UI'; mso-style-textfill-fill-color: black; mso-style-textfill-fill-alpha: 100.0%;"&gt;&lt;span style="color: black; mso-style-textfill-fill-color: black; mso-style-textfill-fill-alpha: 100.0%;"&gt;Windows 7 SDK (contains WPT 4.6)&lt;/span&gt;&lt;/span&gt;&lt;/a&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p style="padding-left: 30px;"&gt;&lt;span style="line-height: 130%; font-family: 'Segoe UI','sans-serif'; color: #333333;"&gt;&lt;span style="font-size: x-small;"&gt;&lt;span style="font-family: arial,helvetica,sans-serif;"&gt;WPT 4.1.1 does not support Windows 7. Windows 7 SDK comes with a version compatible with this OS release. Please obtain WPT from the Platform SDK if you plan on analyzing performance traces from Windows 7 systems.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p style="padding-left: 30px;"&gt;&lt;span style="font-size: x-small;"&gt;&lt;span style="font-family: arial,helvetica,sans-serif;"&gt;&lt;span style="background-color: #ffffff;"&gt;&lt;span style="background-image: none; line-height: 130%; background-attachment: scroll; background-repeat: repeat; background-position: 0% 0%; color: #333333; mso-highlight: yellow;"&gt;The MSIs containing these tools are installed as part of the Win32 Development Tools portion of the Windows SDK. You can use the Web installer to install just the Win32 Development Tools portion of the Windows SDK.&lt;/span&gt;&lt;span style="line-height: 130%; color: #333333;"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal"&gt;&lt;span style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt; mso-bidi-font-family: 'Times New Roman';"&gt;&lt;span style="font-size: x-small;"&gt;&lt;span style="font-family: arial,helvetica,sans-serif;"&gt;&lt;span style="color: #000000;"&gt;When you follow the link you get to&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="font-size: x-small;"&gt;&lt;span style="font-family: arial,helvetica,sans-serif;"&gt;&lt;span style="color: #000080;"&gt;&lt;a href="http://www.microsoft.com/downloads/en/details.aspx?FamilyID=c17ba869-9671-4330-a63e-1fd44e0e2505&amp;amp;displaylang=en"&gt;this&lt;/a&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="font-size: x-small;"&gt;&lt;span style="font-family: arial,helvetica,sans-serif;"&gt;&lt;span style="color: #000000;"&gt;&lt;a href="http://&amp;lt;a target=&amp;quot;_blank&amp;quot; href=&amp;quot;/controlpanel/blogs/posteditor.aspx/this&amp;quot; title=&amp;quot;http://msdn.microsoft.com/en-us/performance/cc752957.aspx&amp;quot;&amp;gt;&amp;lt;span style='font-size: x-small;'&amp;gt;&amp;lt;span style='font-family: arial,helvetica,sans-serif;'&amp;gt;&amp;lt;span style='color: #000080;'&amp;gt;this&amp;lt;/span&amp;gt;&amp;lt;/span&amp;gt;&amp;lt;/span&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;span style='font-size: x-small;'&amp;gt;&amp;lt;span style='font-family: arial,helvetica,sans-serif;'&amp;gt;&amp;lt;span style='color: #000000;'&amp;gt;&amp;amp;nbsp;&amp;lt;/span&amp;gt;&amp;lt;/span&amp;gt;&amp;lt;/span&amp;gt;"&gt;&amp;nbsp;&lt;/a&gt;version of the SDK: but that is an older one. &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;a target="_blank" href="http://www.microsoft.com/downloads/en/details.aspx?FamilyID=6b6c21d2-2006-4afa-9702-529fa782d63b&amp;amp;displaylang=en" title="http://www.microsoft.com/downloads/en/details.aspx?FamilyID=6b6c21d2-2006-4afa-9702-529fa782d63b&amp;amp;displaylang=en"&gt;&lt;span style="font-size: x-small;"&gt;&lt;span style="font-family: arial,helvetica,sans-serif;"&gt;&lt;span style="color: #000080;"&gt;This &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/a&gt;&lt;span style="font-size: x-small;"&gt;&lt;span style="font-family: arial,helvetica,sans-serif;"&gt;&lt;span style="color: #000000;"&gt;is the later version 7.1 with framework 4.0. &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal"&gt;&lt;span style="font-family: 'Calibri','sans-serif'; color: #1f497d; mso-bidi-font-family: 'Times New Roman';"&gt;&lt;span style="font-size: x-small;"&gt;&lt;span style="font-family: arial,helvetica,sans-serif;"&gt;&lt;span style="color: #000000;"&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal"&gt;&lt;span style="font-family: 'Calibri','sans-serif'; color: #1f497d; mso-bidi-font-family: 'Times New Roman';"&gt;&lt;span style="font-size: x-small;"&gt;&lt;span style="font-family: arial,helvetica,sans-serif;"&gt;&lt;span style="color: #000000;"&gt;So you start the web installer and select the following components.&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal"&gt;&lt;span style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt; mso-bidi-font-family: 'Times New Roman';"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal"&gt;&lt;v:shapetype coordsize="21600,21600" o:spt="75" o:preferrelative="t" path="m@4@5l@4@11@9@11@9@5xe" filled="f" stroked="f" id="_x0000_t75"&gt;&lt;v:stroke joinstyle="miter"&gt;&lt;/v:stroke&gt;&lt;v:formulas&gt;&lt;v:f eqn="if lineDrawn pixelLineWidth 0"&gt;&lt;/v:f&gt;&lt;v:f eqn="sum @0 1 0"&gt;&lt;/v:f&gt;&lt;v:f eqn="sum 0 0 @1"&gt;&lt;/v:f&gt;&lt;v:f eqn="prod @2 1 2"&gt;&lt;/v:f&gt;&lt;v:f eqn="prod @3 21600 pixelWidth"&gt;&lt;/v:f&gt;&lt;v:f eqn="prod @3 21600 pixelHeight"&gt;&lt;/v:f&gt;&lt;v:f eqn="sum @0 0 1"&gt;&lt;/v:f&gt;&lt;v:f eqn="prod @6 1 2"&gt;&lt;/v:f&gt;&lt;v:f eqn="prod @7 21600 pixelWidth"&gt;&lt;/v:f&gt;&lt;v:f eqn="sum @8 21600 0"&gt;&lt;/v:f&gt;&lt;v:f eqn="prod @7 21600 pixelHeight"&gt;&lt;/v:f&gt;&lt;v:f eqn="sum @10 21600 0"&gt;&lt;/v:f&gt;&lt;/v:formulas&gt;&lt;v:path o:extrusionok="f" gradientshapeok="t" o:connecttype="rect"&gt;&lt;/v:path&gt;&lt;o:lock v:ext="edit" aspectratio="t"&gt;&lt;/o:lock&gt;&lt;/v:shapetype&gt;&lt;span style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt; mso-bidi-font-family: 'Times New Roman';"&gt;&lt;span style="mso-tab-count: 1;"&gt;&lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal"&gt;&lt;span style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt; mso-bidi-font-family: 'Times New Roman';"&gt;&lt;o:p&gt;&amp;nbsp;&lt;span style="font-size: small;"&gt;&lt;span style="font-family: arial,helvetica,sans-serif;"&gt;&lt;img src="http://blogs.msdn.com/resized-image.ashx/__size/550x0/__key/CommunityServer-Blogs-Components-WeblogFiles/00-00-00-92-29/8203.Capture.PNG" border="0" /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal"&gt;&lt;span style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt; mso-bidi-font-family: 'Times New Roman';"&gt;When that finishes, the install is buried in the&amp;nbsp;tools&amp;nbsp;menu under Install Windows Performance Tools:&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal"&gt;&lt;span style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt; mso-bidi-font-family: 'Times New Roman';"&gt;&lt;o:p&gt;&lt;img src="http://blogs.msdn.com/resized-image.ashx/__size/550x0/__key/CommunityServer-Blogs-Components-WeblogFiles/00-00-00-92-29/3482.Capture1.PNG" border="0" /&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal"&gt;&lt;span style="font-family: 'Calibri','sans-serif'; color: #1f497d; font-size: 11pt; mso-bidi-font-family: 'Times New Roman';"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=10092632" width="1" height="1"&gt;</content><author><name>Maarten van de Bospoort MSFT</name><uri>http://blogs.msdn.com/maartenb/ProfileUrlRedirect.ashx</uri></author></entry><entry><title>Getting IAT for all drivers from a Kernel Dump</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/b/maartenb/archive/2010/04/22/getting-iat-for-all-drivers-from-a-kernel-dump.aspx" /><id>http://blogs.msdn.com/b/maartenb/archive/2010/04/22/getting-iat-for-all-drivers-from-a-kernel-dump.aspx</id><published>2010-04-22T21:23:49Z</published><updated>2010-04-22T21:23:49Z</updated><content type="html">&lt;p&gt;For some obscure reasons, I needed the Import Address Table (IAT) of specific modules from a kernel dump. Actually I needed them for all modules from potentially a whole lot of dumps. Getting the IAT for one module is straightforward:
&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;div&gt;Get the address of a module. For example for smb.sys
&lt;/div&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Courier New"&gt;1: kd&amp;gt; lm msmb
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Courier New"&gt;start    end        module name
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Courier New"&gt;&lt;strong&gt;9c03e000&lt;/strong&gt; 9c054000   smb        
&lt;/span&gt;&lt;/p&gt;&lt;p&gt;
 &lt;/p&gt;&lt;/li&gt;&lt;li&gt;&lt;div&gt;Dump the headers
&lt;/div&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Courier New"&gt;1: kd&amp;gt; !dh /f &lt;strong&gt;9c03e000&lt;/strong&gt;
				&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;
 &lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Courier New"&gt;File Type: EXECUTABLE IMAGE
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Courier New"&gt;FILE HEADER VALUES
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Courier New"&gt;     14C machine (i386)
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Courier New"&gt;       7 number of sections
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Courier New"&gt;4A5BC903 time date stamp Mon Jul 13 16:53:39 2009
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;
 &lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Courier New"&gt;…
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;
 &lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Courier New"&gt;       0 [       0] address [size] of Special Directory
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Courier New"&gt;       0 [       0] address [size] of Thread Storage Directory
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Courier New"&gt;       0 [       0] address [size] of Load Configuration Directory
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Courier New"&gt;       0 [       0] address [size] of Bound Import Directory
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Courier New"&gt;&lt;strong&gt;    C000 [     1F4] address [size] of Import Address Table Directory
&lt;/strong&gt;&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Courier New"&gt;       0 [       0] address [size] of Delay Import Directory
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Courier New"&gt;       0 [       0] address [size] of COR20 Header Directory
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Courier New"&gt;       0 [       0] address [size] of Reserved Directory
&lt;/span&gt;&lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;
 &lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;div&gt;Dump the IAT
&lt;/div&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Courier New"&gt;1: kd&amp;gt; dds 9c03e000+&lt;strong&gt;C000&lt;/strong&gt; 9c03e000+&lt;strong&gt;C000&lt;/strong&gt;+&lt;strong&gt;1F4&lt;/strong&gt;
				&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Courier New"&gt;9c04a000  82e06700 hal!KfAcquireSpinLock 
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Courier New"&gt;9c04a004  82e086ee hal!KeGetCurrentIrql 
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Courier New"&gt;9c04a008  82e067a0 hal!KfReleaseSpinLock 
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;&lt;span style="font-family:Courier New"&gt;…
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 36pt"&gt;
 &lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;But that is all very manual. I would like to iterate over all modules in the dump and spit out the IAT to a text file or so. Excellent opportunity to finally learn WinDbg scripts. So here is the result:
&lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;&lt;span style="font-family:Courier New"&gt;$$ run like this: $$&amp;gt;a&amp;lt;" IAT.txt"
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;
 &lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;&lt;span style="font-family:Courier New"&gt;.logopen /t @"mylogfile.txt"
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;
 &lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;&lt;span style="font-family:Courier New"&gt;.echo =========================================
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;&lt;span style="font-family:Courier New"&gt;.echo Get IAT for all modules
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;&lt;span style="font-family:Courier New"&gt;.echo =========================================
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;
 &lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;&lt;span style="font-family:Courier New"&gt;$$ get offset of NT Header offset 
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;&lt;span style="font-family:Courier New"&gt;r? $t1 = #FIELD_OFFSET(_IMAGE_DOS_HEADER , e_lfanew )
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;
 &lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;&lt;span style="font-family:Courier New"&gt;$$ get offset of OptionalHeader and store it
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;&lt;span style="font-family:Courier New"&gt;r? $t3 = #FIELD_OFFSET(_IMAGE_NT_HEADERS, OptionalHeader)
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;
 &lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;&lt;span style="font-family:Courier New"&gt;$$ get offset of DataDirectory and store
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;&lt;span style="font-family:Courier New"&gt;r? $t4 = #FIELD_OFFSET(_IMAGE_OPTIONAL_HEADER, DataDirectory)
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;
 &lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;&lt;span style="font-family:Courier New"&gt;$$ Iterate over each base address, get to the IAT address 
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;&lt;span style="font-family:Courier New"&gt;!for_each_module "r $t0 = @#Base; .echo ==== @#ModuleName; 
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;&lt;span style="font-family:Courier New"&gt;r $t2=poi(@$t0+@$t1);
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;&lt;span style="font-family:Courier New"&gt;r $t5=poi(@$t0+@$t2+@$t3+@$t4+0n12*0x8);
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;&lt;span style="font-family:Courier New"&gt;r $t6=poi(@$t0+@$t2+@$t3+@$t4+0n12*0x8+0x4);
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;&lt;span style="font-family:Courier New"&gt;dds @$t0 + @$t5 @$t0 + @$t5 + @$t6"
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;
 &lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;&lt;span style="font-family:Courier New"&gt;.logclose
&lt;/span&gt;&lt;/p&gt;&lt;p&gt;
 &lt;/p&gt;&lt;p&gt;There are probably better ways of doing this. But it gets the job done and I wrote my first script &lt;span style="font-family:Wingdings"&gt;J&lt;/span&gt;. And the output
&lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;&lt;span style="font-family:Courier New"&gt;Opened log file 'D:\Playground7\OCA Reclassification\mylogfile_0820_2010-04-21_15-25-53-872.txt'
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;&lt;span style="font-family:Courier New"&gt;=========================================
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;&lt;span style="font-family:Courier New"&gt;Get IAT for all modules
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;&lt;span style="font-family:Courier New"&gt;=========================================
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;&lt;span style="font-family:Courier New"&gt;==== kdcom
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;&lt;span style="font-family:Courier New"&gt;80bc9000  82e1bfe4 hal!READ_PORT_UCHAR 
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;&lt;span style="font-family:Courier New"&gt;80bc9004  82e1c04c hal!WRITE_PORT_UCHAR 
&lt;/span&gt;&lt;/p&gt;&lt;p style="margin-left: 72pt"&gt;&lt;span style="font-family:Courier New"&gt;…&lt;/span&gt;&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=10001081" width="1" height="1"&gt;</content><author><name>Maarten van de Bospoort MSFT</name><uri>http://blogs.msdn.com/maartenb/ProfileUrlRedirect.ashx</uri></author></entry><entry><title>Who changed my Platform Timer Resolution?</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/b/maartenb/archive/2010/02/28/who-changed-my-platform-timer-resolution.aspx" /><id>http://blogs.msdn.com/b/maartenb/archive/2010/02/28/who-changed-my-platform-timer-resolution.aspx</id><published>2010-03-01T01:36:00Z</published><updated>2010-03-01T01:36:00Z</updated><content type="html">&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;When you run powercfg /energy from an elevated command line&amp;nbsp;you can get this:&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;o:p&gt;&lt;FONT size=3 face=Calibri&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;BLOCKQUOTE&gt;
&lt;P style="MARGIN: 0in 0in 0pt; mso-margin-top-alt: auto; mso-margin-bottom-alt: auto; mso-outline-level: 4" class=MsoNormal&gt;&lt;B&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 12pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;Warnings&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/B&gt;&lt;/P&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;B&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 10pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;Platform Timer Resolution:Platform Timer Resolution&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/B&gt;&lt;/P&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 10pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;The default platform timer resolution is 15.6ms (15625000ns) and should be used whenever the system is idle. If the timer resolution is increased, processor power management technologies may not be effective. The timer resolution may be increased due to multimedia playback or graphical animations.&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;TABLE style="mso-cellspacing: 1.5pt; mso-yfti-tbllook: 1184" class=MsoNormalTable border=0 cellSpacing=3 cellPadding=0 class="MsoNormalTable"&gt;
&lt;TBODY&gt;
&lt;TR style="mso-yfti-irow: 0; mso-yfti-firstrow: yes"&gt;
&lt;TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; PADDING-BOTTOM: 3pt; BACKGROUND-COLOR: transparent; PADDING-LEFT: 3pt; PADDING-RIGHT: 3pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0; PADDING-TOP: 3pt"&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 10pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;Current Timer Resolution (100ns units)&lt;B&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/B&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;
&lt;TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; PADDING-BOTTOM: 3pt; BACKGROUND-COLOR: transparent; PADDING-LEFT: 3pt; PADDING-RIGHT: 3pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0; PADDING-TOP: 3pt"&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;B&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 10pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;25000&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/B&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR style="mso-yfti-irow: 1; mso-yfti-lastrow: yes"&gt;
&lt;TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; PADDING-BOTTOM: 3pt; BACKGROUND-COLOR: transparent; PADDING-LEFT: 3pt; PADDING-RIGHT: 3pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0; PADDING-TOP: 3pt"&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 10pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;Maximum Timer Period (100ns units)&lt;B&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/B&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;
&lt;TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; PADDING-BOTTOM: 3pt; BACKGROUND-COLOR: transparent; PADDING-LEFT: 3pt; PADDING-RIGHT: 3pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0; PADDING-TOP: 3pt"&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;B&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 10pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;156001&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/B&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;B&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 10pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;Platform Timer Resolution:Outstanding Timer Request&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/B&gt;&lt;/P&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 10pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;A program or service has requested a timer resolution smaller than the platform maximum timer resolution.&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;TABLE style="mso-cellspacing: 1.5pt; mso-yfti-tbllook: 1184" class=MsoNormalTable border=0 cellSpacing=3 cellPadding=0 class="MsoNormalTable"&gt;
&lt;TBODY&gt;
&lt;TR style="mso-yfti-irow: 0; mso-yfti-firstrow: yes"&gt;
&lt;TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; PADDING-BOTTOM: 3pt; BACKGROUND-COLOR: transparent; PADDING-LEFT: 3pt; PADDING-RIGHT: 3pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0; PADDING-TOP: 3pt"&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 10pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;Requested Period&lt;B&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/B&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;
&lt;TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; PADDING-BOTTOM: 3pt; BACKGROUND-COLOR: transparent; PADDING-LEFT: 3pt; PADDING-RIGHT: 3pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0; PADDING-TOP: 3pt"&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;B&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 10pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;30000&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/B&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR style="mso-yfti-irow: 1"&gt;
&lt;TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; PADDING-BOTTOM: 3pt; BACKGROUND-COLOR: transparent; PADDING-LEFT: 3pt; PADDING-RIGHT: 3pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0; PADDING-TOP: 3pt"&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 10pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;Requesting Process ID&lt;B&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/B&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;
&lt;TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; PADDING-BOTTOM: 3pt; BACKGROUND-COLOR: transparent; PADDING-LEFT: 3pt; PADDING-RIGHT: 3pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0; PADDING-TOP: 3pt"&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;B&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 10pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;8308&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/B&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR style="mso-yfti-irow: 2; mso-yfti-lastrow: yes"&gt;
&lt;TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; PADDING-BOTTOM: 3pt; BACKGROUND-COLOR: transparent; PADDING-LEFT: 3pt; PADDING-RIGHT: 3pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0; PADDING-TOP: 3pt"&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 10pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;Requesting Process Path&lt;B&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/B&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;
&lt;TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; PADDING-BOTTOM: 3pt; BACKGROUND-COLOR: transparent; PADDING-LEFT: 3pt; PADDING-RIGHT: 3pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0; PADDING-TOP: 3pt"&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;B&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 10pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;\Device\HarddiskVolume4\Playground7\DebugTest\Debug\DebugTest.exe&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/B&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/BLOCKQUOTE&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;o:p&gt;&lt;FONT size=3 face=Calibri&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;From a power consumption persective, having an elevated more frequent timer might not be the most optimal. &lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;&lt;/FONT&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;Then in the informational section you get this:&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;o:p&gt;&lt;FONT size=3 face=Calibri&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;BLOCKQUOTE style="MARGIN-RIGHT: 0px" dir=ltr&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;B&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 10pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;Platform Timer Resolution:Timer Request Stack&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/B&gt;&lt;/P&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 10pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;The stack of modules responsible for the lowest platform timer setting in this process.&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;
&lt;TABLE style="mso-cellspacing: 1.5pt; mso-yfti-tbllook: 1184" class=MsoNormalTable border=0 cellSpacing=3 cellPadding=0 class="MsoNormalTable"&gt;
&lt;TBODY&gt;
&lt;TR style="mso-yfti-irow: 0; mso-yfti-firstrow: yes"&gt;
&lt;TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; PADDING-BOTTOM: 3pt; BACKGROUND-COLOR: transparent; PADDING-LEFT: 3pt; PADDING-RIGHT: 3pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0; PADDING-TOP: 3pt"&gt;
&lt;BLOCKQUOTE style="MARGIN-RIGHT: 0px" dir=ltr&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 10pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;Requested Period&lt;B&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/B&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;/TD&gt;
&lt;TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; PADDING-BOTTOM: 3pt; BACKGROUND-COLOR: transparent; PADDING-LEFT: 3pt; PADDING-RIGHT: 3pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0; PADDING-TOP: 3pt"&gt;
&lt;BLOCKQUOTE style="MARGIN-RIGHT: 0px" dir=ltr&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;B&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 10pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;30000&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/B&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR style="mso-yfti-irow: 1"&gt;
&lt;TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; PADDING-BOTTOM: 3pt; BACKGROUND-COLOR: transparent; PADDING-LEFT: 3pt; PADDING-RIGHT: 3pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0; PADDING-TOP: 3pt"&gt;
&lt;BLOCKQUOTE style="MARGIN-RIGHT: 0px" dir=ltr&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 10pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;Requesting Process ID&lt;B&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/B&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;/TD&gt;
&lt;TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; PADDING-BOTTOM: 3pt; BACKGROUND-COLOR: transparent; PADDING-LEFT: 3pt; PADDING-RIGHT: 3pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0; PADDING-TOP: 3pt"&gt;
&lt;BLOCKQUOTE style="MARGIN-RIGHT: 0px" dir=ltr&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;B&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 10pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;8308&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/B&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR style="mso-yfti-irow: 2"&gt;
&lt;TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; PADDING-BOTTOM: 3pt; BACKGROUND-COLOR: transparent; PADDING-LEFT: 3pt; PADDING-RIGHT: 3pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0; PADDING-TOP: 3pt"&gt;
&lt;BLOCKQUOTE style="MARGIN-RIGHT: 0px" dir=ltr&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 10pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;Requesting Process Path&lt;B&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/B&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;/TD&gt;
&lt;TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; PADDING-BOTTOM: 3pt; BACKGROUND-COLOR: transparent; PADDING-LEFT: 3pt; PADDING-RIGHT: 3pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0; PADDING-TOP: 3pt"&gt;
&lt;BLOCKQUOTE style="MARGIN-RIGHT: 0px" dir=ltr&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;B&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 10pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;\Device\HarddiskVolume4\Playground7\DebugTest\Debug\DebugTest.exe&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/B&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR style="mso-yfti-irow: 3"&gt;
&lt;TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; PADDING-BOTTOM: 3pt; BACKGROUND-COLOR: transparent; PADDING-LEFT: 3pt; PADDING-RIGHT: 3pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0; PADDING-TOP: 3pt"&gt;
&lt;BLOCKQUOTE style="MARGIN-RIGHT: 0px" dir=ltr&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 10pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;Calling Module Stack &lt;B&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/B&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;/TD&gt;
&lt;TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; PADDING-BOTTOM: 3pt; BACKGROUND-COLOR: transparent; PADDING-LEFT: 3pt; PADDING-RIGHT: 3pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0; PADDING-TOP: 3pt"&gt;
&lt;BLOCKQUOTE style="MARGIN-RIGHT: 0px" dir=ltr&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;B&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 10pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;\Device\HarddiskVolume2\Windows\SysWOW64\ntdll.dll&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/B&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR style="mso-yfti-irow: 4"&gt;
&lt;TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; PADDING-BOTTOM: 3pt; BACKGROUND-COLOR: transparent; PADDING-LEFT: 3pt; PADDING-RIGHT: 3pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0; PADDING-TOP: 3pt"&gt;
&lt;BLOCKQUOTE style="MARGIN-RIGHT: 0px" dir=ltr&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;/TD&gt;
&lt;TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; PADDING-BOTTOM: 3pt; BACKGROUND-COLOR: transparent; PADDING-LEFT: 3pt; PADDING-RIGHT: 3pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0; PADDING-TOP: 3pt"&gt;
&lt;BLOCKQUOTE style="MARGIN-RIGHT: 0px" dir=ltr&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;B&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 10pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;\Device\HarddiskVolume2\Windows\SysWOW64\winmm.dll&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/B&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR style="mso-yfti-irow: 5"&gt;
&lt;TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; PADDING-BOTTOM: 3pt; BACKGROUND-COLOR: transparent; PADDING-LEFT: 3pt; PADDING-RIGHT: 3pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0; PADDING-TOP: 3pt"&gt;
&lt;BLOCKQUOTE style="MARGIN-RIGHT: 0px" dir=ltr&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;/TD&gt;
&lt;TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; PADDING-BOTTOM: 3pt; BACKGROUND-COLOR: transparent; PADDING-LEFT: 3pt; PADDING-RIGHT: 3pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0; PADDING-TOP: 3pt"&gt;
&lt;BLOCKQUOTE style="MARGIN-RIGHT: 0px" dir=ltr&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;B&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 10pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;\Device\HarddiskVolume4\Playground7\DebugTest\Debug\DebugTest.exe&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/B&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR style="mso-yfti-irow: 6"&gt;
&lt;TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; PADDING-BOTTOM: 3pt; BACKGROUND-COLOR: transparent; PADDING-LEFT: 3pt; PADDING-RIGHT: 3pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0; PADDING-TOP: 3pt"&gt;
&lt;BLOCKQUOTE style="MARGIN-RIGHT: 0px" dir=ltr&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;/TD&gt;
&lt;TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; PADDING-BOTTOM: 3pt; BACKGROUND-COLOR: transparent; PADDING-LEFT: 3pt; PADDING-RIGHT: 3pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0; PADDING-TOP: 3pt"&gt;
&lt;BLOCKQUOTE style="MARGIN-RIGHT: 0px" dir=ltr&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;B&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 10pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;\Device\HarddiskVolume2\Windows\SysWOW64\kernel32.dll&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/B&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR style="mso-yfti-irow: 7; mso-yfti-lastrow: yes"&gt;
&lt;TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; PADDING-BOTTOM: 3pt; BACKGROUND-COLOR: transparent; PADDING-LEFT: 3pt; PADDING-RIGHT: 3pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0; PADDING-TOP: 3pt"&gt;
&lt;BLOCKQUOTE style="MARGIN-RIGHT: 0px" dir=ltr&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;/TD&gt;
&lt;TD style="BORDER-BOTTOM: #f0f0f0; BORDER-LEFT: #f0f0f0; PADDING-BOTTOM: 3pt; BACKGROUND-COLOR: transparent; PADDING-LEFT: 3pt; PADDING-RIGHT: 3pt; BORDER-TOP: #f0f0f0; BORDER-RIGHT: #f0f0f0; PADDING-TOP: 3pt"&gt;
&lt;BLOCKQUOTE style="MARGIN-RIGHT: 0px" dir=ltr&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;B&gt;&lt;SPAN style="FONT-FAMILY: 'Verdana','sans-serif'; FONT-SIZE: 10pt; mso-fareast-font-family: 'Times New Roman'; mso-bidi-font-family: 'Times New Roman'"&gt;\Device\HarddiskVolume2\Windows\SysWOW64\ntdll.dll&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/B&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;o:p&gt;&lt;FONT size=3 face=Calibri&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;FONT size=3 face=Calibri&gt;But that still doesn’t give me the source, nor what API to look for. One of the API calls that can be responsible for this is the &lt;/FONT&gt;&lt;A href="http://msdn.microsoft.com/en-us/library/dd757624(VS.85).aspx" mce_href="http://msdn.microsoft.com/en-us/library/dd757624(VS.85).aspx"&gt;&lt;FONT size=3 face=Calibri&gt;timeBeginPeriod&lt;/FONT&gt;&lt;/A&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt; function. Then it becomes as easy as setting a breakpoint on winmm!timeBeginPeriod in WinDbg and voila. There might be more API calls that change the timer.&amp;nbsp;&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;[Edit] The more interesting API is obviously &lt;SPAN style="FONT-FAMILY: 'Arial','sans-serif'; FONT-SIZE: 12pt; mso-fareast-font-family: Calibri; mso-fareast-theme-font: minor-latin; mso-ansi-language: EN-US; mso-fareast-language: EN-US; mso-bidi-language: AR-SA"&gt;ntdll32!NtSetTimerResolution&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9970606" width="1" height="1"&gt;</content><author><name>Maarten van de Bospoort MSFT</name><uri>http://blogs.msdn.com/maartenb/ProfileUrlRedirect.ashx</uri></author></entry><entry><title>My COM server is gone from Component Services (DCOMCNFG)</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/b/maartenb/archive/2010/01/15/my-com-server-is-gone-from-component-services-dcomcnfg.aspx" /><id>http://blogs.msdn.com/b/maartenb/archive/2010/01/15/my-com-server-is-gone-from-component-services-dcomcnfg.aspx</id><published>2010-01-15T19:09:00Z</published><updated>2010-01-15T19:09:00Z</updated><content type="html">&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;Here’s a problem a partner ran into last month. Suppose you have an ActiveX server (in this case it was a VB6 COM Executable) registered on x64 bit Windows Server 2008 or Vista. You open up Component Services and you find your server under “Component&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/SPAN&gt;Services\Computers\My Computer\DCOM Config”. Those&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/SPAN&gt;same COM servers however don’t show up in that location under 64 bit versions of Windows 7 or Windows Server 2008 R2. How come?&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;o:p&gt;&lt;FONT size=3 face=Calibri&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;First some background. When you register a COM server (myserver.exe /regserver), the server’s registration code has&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/SPAN&gt;full control over what is entered in the registry. Most of the time frameworks such as ATL, MFC or VB take care of this in plumbing code. Apparently VB6 ActiveX servers don’t add the AppID. Spelunking around a little with procmon, the MMC snap-in for component services apparently enumerates all COM servers and adds the missing entries. It still does this on all platforms, so why the problem? &lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;o:p&gt;&lt;FONT size=3 face=Calibri&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;FONT size=3 face=Calibri&gt;As mentioned this problem only manifests itself on x64 Windows 7 and Windows Server 2008 R2. The x64 bit versions of Vista and WS08 don’t manifest this problem. So what has changed? The answer is &lt;/FONT&gt;&lt;A href="http://msdn.microsoft.com/en-us/library/dd464643%28VS.85%29.aspx"&gt;&lt;FONT color=#0000ff size=3 face=Calibri&gt;COM Reflection&lt;/FONT&gt;&lt;/A&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;. When you register the COM Server on platforms prior to Windows 7 on an x64 system, the CLSID is copied from HKCR\Wow6432\CLSID to HKCR\CLSID. The MMC Component Services snap-in enumerates and fixes up only the “native” HKCR\CLSID. Since the values for 32 bit servers is no longer copied to that hive, you won’t see it in the 64 bit snap-in. &lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;o:p&gt;&lt;FONT size=3 face=Calibri&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P style="MARGIN: 0in 0in 0pt" class=MsoNormal&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;There is a trivial workaround for this. You can open a 32 bit mmc by typing “mmc -32” on the command line. Then add the Component Services snap-in from there. That will fix up the missing AppID entries. Once the entries are added you can use the 64 bit DCOMCNFG again. &lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9949086" width="1" height="1"&gt;</content><author><name>Maarten van de Bospoort MSFT</name><uri>http://blogs.msdn.com/maartenb/ProfileUrlRedirect.ashx</uri></author></entry><entry><title>Disabling a Shim (part II)</title><link rel="alternate" type="text/html" href="http://blogs.msdn.com/b/maartenb/archive/2009/07/29/disabling-a-shim-part-ii.aspx" /><id>http://blogs.msdn.com/b/maartenb/archive/2009/07/29/disabling-a-shim-part-ii.aspx</id><published>2009-07-29T19:15:18Z</published><updated>2009-07-29T19:15:18Z</updated><content type="html">&lt;p&gt;Follow-up from the research on &lt;a href="http://blogs.msdn.com/maartenb/archive/2009/07/24/disabling-a-shim.aspx"&gt;how to disable a per-application shim&lt;/a&gt;. When I saw the output from the shim infrastructure in DebugView, I mistakenly assumed that the application was shimmed. It apparently only means that the application is found in the AppCompat system database. It does &lt;em&gt;not&lt;/em&gt; mean that the shim is actually still in place. 
&lt;/p&gt;&lt;p&gt;Which leaves me with the question, how do I easily verify that an application is not shimmed (short of the earlier mentioned shotgun approach of turning the whole shim engine off)? Someone who does this for a living told me that one way you can tell is whether aclayers.dll is loaded in the process. He also told me that getting an application shim free is not that easy. There are all kinds of watchdogs in the system monitoring and instrumenting applications. 
&lt;/p&gt;&lt;p&gt;When an application entry is disabled in &lt;a href="http://www.microsoft.com/downloads/details.aspx?FamilyId=24DA89E9-B581-47B0-B45E-492DD6DA2971&amp;amp;displaylang=en"&gt;ACT&lt;/a&gt;, I see with Process Explorer two environment variables that indicate to me they have something to do with Application Compatibility or shimming:  __COMPAT_LAYER = VistaSetup and SHIM_DEBUG_LEVEL = 9. The last one was added by me for the logging. I also see AcGeneral.dll and apphelp.dll loaded in the process. And it is wrapped in a job (you can tell by looking at the process properties in Process Explorer; there is a Job tab). 
&lt;/p&gt;&lt;p&gt;When I reenable the entry, I see  __COMPAT_LAYER=VistaSetup &lt;strong&gt;WinXPSp2_GW&lt;/strong&gt; and the same SHIM_DEBUG_LEVEL=9. This WinXPSp2_GW matches the entry in the ACT database. This somewhat confirms that disabling an entry does indeed have the desired effect. Also an additional dll was loaded: the before mentioned aclayers.dll. 
&lt;/p&gt;&lt;p&gt;When the &lt;a href="http://msdn.microsoft.com/en-us/library/bb756937.aspx"&gt;PCA&lt;/a&gt; notices your application as a setup, it will flag it in the registry. This was my case and I was thinking maybe, the VistaSetup CompatLayer comes from there. I made sure the application was not flagged anywhere under (\AppCompatFlags\Compatibility Assistant\Persisted.) No difference. VistaSetup was still there. 
&lt;/p&gt;&lt;p&gt;Then I disabled the Program Compatibility Assistant service. The effect of that was that the process is no longer wrapped inside a job. However the service restarts quickly. I had to disable it to make sure it didn't get in the way. Still the VistaSetup was there as an environment variable. 
&lt;/p&gt;&lt;p&gt;My current assumption is that the VistaSetup layer is coming from the fact that there is no Windows 7 &lt;a href="http://msdn.microsoft.com/en-us/library/dd371711(VS.85).aspx"&gt;switchback entry in the manifest&lt;/a&gt;. It apparently is also detected as a setup. I will need to verify it by adding the switchback GUID. That is for next time. &lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9852246" width="1" height="1"&gt;</content><author><name>Maarten van de Bospoort MSFT</name><uri>http://blogs.msdn.com/maartenb/ProfileUrlRedirect.ashx</uri></author></entry></feed>