At what point does it restart?
At the logon screen, at the xp loading screen, welcome screen, bios ?!?!
If it happens at the user screen then it might be your profile corrupted. Go to safe mode and try making a new user.
If it restarts at the xp loading screen, press F8 at startup repeatedly, and see if U can access safemode.
If so, ty a system restore from Start>Run and type msconfig and ok. Click Launch System restore. Restore to a previous date.
If not, try on the F8 menu Last good known config, or U disable automatic restart to see if U get a blue error screen. What is the error code or the files related to it? *.sys? *.dll?
If U can't go to safemode, then try loading bios defaults (F2 or del at tartup)