Could be a heat issue.
I have a Dell Dimension E510 desktop running Windows XP Professional. For the past 2 weeks it randomly shuts down and tries to restart itself 4-5 times before it finally reboots. When it shuts down it loses power. I have replaced the power supply. That did not stop this problem. I have also run a number of spyware software and cleaned my system. That did not stop this problem. I have also started it in safe mode. That did not stop the shutdowns. Could it be the motherboard? Any suggestions?