title: Windows Safe Mode runs simple programs (at least) 3 times faster?
body: <p>While doing a lot of benchmarking stuff these days, I stumbled upon something very disturbing / interesting / new to me. After doing some research getting more and more to the point (which i couldnt believe), it seems that windows xp (and probably all other versions as well) runs programs around 3 times as slow as in safe mode. </p>
  
  <p>Take this small program as an example:</p>
  
  <pre><code>#include &lt;stdio.h&gt;
  #include &lt;stdlib.h&gt;
  
  int main(int argc, char **argv)
  {
  
      long    i,j,k;
  
      printf ("Starting...\n");
  
      k = 12;
  
      for (i = 0; i &lt; 20000; i++)
          for (j = 100000; j &gt; 0; j--)
              k = k * 12;
  
      printf ("Done... k =%d", k);     // just using k here to prevent the whole block isn't optimized away.
  
      return 0;
  }
  </code></pre>
  
  <p>On my 2.4 Ghz computer it takes ~ 2.5 secs to execute in safe mode, while it takes ~ 8 secs to execute in normal mode. (ThreadPriority = TIMECRITICAL, ProcessClass = REALTIME).
  EVEN when i compile and start that code within a vmware-linux session under this very windows normal mode it executes faster (around 5.5 secs). </p>
  
  <p>I also did a lot of cpu cycle measuring and actually the results from safe mode seem much 
  more like what you should expect given the amount of instructions processed.</p>
  
  <p>So what did i miss ? Can anybody riddle me this ?</p>
  
  <p>All pointers and hints appreciated,
  Thanx.</p>
  
  <p><strong>SOLVED!</strong> I am sorry guys, this issue is related to my crappy <strong>alienware m15x</strong> which for some reason is throttling down to apparently 1/3 of its cpu power - unless you use evil tools (ThrottleStop.exe) to bring it up to normal speed. Devastatingly sorry for wasting your time. :(</p>