100 cpu utilisation

100 cpu utilisation

 

       Do you want to see how infinite loop can affect performance of the application? Here is the proof.
Write down simple code below and monitor the CPU utilzation.
you can use any language to test.

protected void Page_Load(object sender, EventArgs e)
{  

while(true);

}

 



Look after running this infinite loop CPU utilzation raised to 100%.
Remember don;t use infinite loops.

Currently rated 5.0 by 1 people

  • Currently 5/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5