Well….I would say if you don’t know when the problem started (or dont have a restore point before the problem) and you have had problems with system restore before that it might be better to leave it be. I know system restore can be a bit fickle over how good it works and what not. If you do decided though to do system restore in the future, remember that if it does slow down your pc after doing a system restore you can always do another system restore back to the time before you did the initial system restore, if that makes sense. That should hopefully put your computer back to its original quicker state.
As for whether system restore is the only way to fix it question: no it is not the only way to fix it. If you can find out where the possible spyware/affected program is on your computer and remove it fully then that would help. With my friends computer she had more than 1 message box coming up at the end and after I manually found and removed some of the offending spyware programmes on her computer one of the message boxes stopped appearing.
You could try installing this free program (CCleaner http://www.ccleaner.com/ ) which allows you to alter what programs as initially run when you start windows. This will allow you to see if there is a simple explanation towards which program you are having the trouble with.
Although for my friends pc we found it was practically impossible to find all the problem programmes. With hers we just left it having that one problem since all it is, is one message box whenever shutting down. But I would say if you go with this option, make sure you have everything backup. Therefore if something seriously does go wrong due to the problem at least you will not have lost all your files.
The other option, which I always go for whenever I start noticing too many things not working 100% right on my computer is a complete reformat and reinstallation of windows and all programmes. Not only does this remove the original problem but it will make your computer as good as new again (since over time with general use and without a reformat the computer will gradually slow down). If you have a genuine copy of Windows XP (genuine being a copy from windows as opposed to one which has been modified by the computer manufactory to only run on their machines), then this is relatively easy to do if you are confident with installing programs. Just remember to first take off all the files which you want to keep before you start.
Hope that helps towards whatever you decided to do.